Skip to content

Commit

Permalink
fixed GC/NC waypoint inpupt: text-transform:uppercase will display up…
Browse files Browse the repository at this point in the history
…percase but not transform
  • Loading branch information
following5 committed Jun 20, 2015
1 parent 1303bcd commit 3791177
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions htdocs/editcache.php
Expand Up @@ -217,8 +217,8 @@ function getWaypoints($cacheid)

$log_pw = isset($_POST['log_pw']) ? mb_substr($_POST['log_pw'], 0, 20) : $cache_record['logpw'];
// fix #4356: gc waypoints are frequently copy&pasted with leading spaces
$wp_gc = isset($_POST['wp_gc']) ? trim($_POST['wp_gc']) : $cache_record['wp_gc']; // Ocprop
$wp_nc = isset($_POST['wp_nc']) ? trim($_POST['wp_nc']) : $cache_record['wp_nc'];
$wp_gc = isset($_POST['wp_gc']) ? strtoupper(trim($_POST['wp_gc'])) : $cache_record['wp_gc']; // Ocprop
$wp_nc = isset($_POST['wp_nc']) ? strtoupper(trim($_POST['wp_nc'])) : $cache_record['wp_nc'];

// name
$name_not_ok = false;
Expand Down
4 changes: 2 additions & 2 deletions htdocs/newcache.php
Expand Up @@ -275,10 +275,10 @@

// gc- and nc-waypoints
// fix #4356: gc waypoints are frequently copy&pasted with leading spaces
$wp_gc = isset($_POST['wp_gc']) ? trim($_POST['wp_gc']) : ''; // Ocprop
$wp_gc = isset($_POST['wp_gc']) ? strtoupper(trim($_POST['wp_gc'])) : ''; // Ocprop
tpl_set_var('wp_gc', htmlspecialchars($wp_gc, ENT_COMPAT, 'UTF-8'));

$wp_nc = isset($_POST['wp_nc']) ? trim($_POST['wp_nc']) : '';
$wp_nc = isset($_POST['wp_nc']) ? strtoupper(trim($_POST['wp_nc'])) : '';
tpl_set_var('wp_nc', htmlspecialchars($wp_nc, ENT_COMPAT, 'UTF-8'));

//difficulty
Expand Down

0 comments on commit 3791177

Please sign in to comment.