#4356 abgeschnittene GC-Wegpunkte durch Leerzeicheneingabe
This commit is contained in:
@ -224,8 +224,9 @@ function getWaypoints($cacheid)
|
||||
}
|
||||
|
||||
$log_pw = isset($_POST['log_pw']) ? mb_substr($_POST['log_pw'], 0, 20) : $cache_record['logpw'];
|
||||
$wp_gc = isset($_POST['wp_gc']) ? $_POST['wp_gc'] : $cache_record['wp_gc'];
|
||||
$wp_nc = isset($_POST['wp_nc']) ? $_POST['wp_nc'] : $cache_record['wp_nc'];
|
||||
// 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'];
|
||||
$wp_nc = isset($_POST['wp_nc']) ? trim($_POST['wp_nc']) : $cache_record['wp_nc'];
|
||||
|
||||
// name
|
||||
$name_not_ok = false;
|
||||
|
@ -233,7 +233,8 @@ function toggleAttr(id)
|
||||
|
||||
<tr>
|
||||
<td>{t}Waypoints (optional):{/t}</td>
|
||||
<td>geocaching.com: <input type="text" name="wp_gc" value="{wp_gc}" maxlength="7" class="input50">
|
||||
<!-- allow wp_gc copy&paste with leading spaces; will be trimmed later -->
|
||||
<td>geocaching.com: <input type="text" name="wp_gc" value="{wp_gc}" maxlength="12" class="input50">
|
||||
navicache.com: <input type="text" name="wp_nc" value="{wp_nc}" maxlength="6" class="input50">
|
||||
</td>
|
||||
</tr>
|
||||
|
@ -230,7 +230,8 @@ function toggleAttr(id)
|
||||
|
||||
<tr>
|
||||
<td>{t}Waypoints:{/t}</td>
|
||||
<td>geocaching.com: <input type="text" name="wp_gc" value="{wp_gc}" maxlength="7" class="input50">
|
||||
<!-- allow wp_gc copy&paste with leading spaces; will be trimmed later -->
|
||||
<td>geocaching.com: <input type="text" name="wp_gc" value="{wp_gc}" maxlength="12" class="input50">
|
||||
navicache.com: <input type="text" name="wp_nc" value="{wp_nc}" maxlength="6" class="input50">
|
||||
</td>
|
||||
</tr>
|
||||
|
@ -282,10 +282,11 @@
|
||||
tpl_set_var('log_pw', htmlspecialchars($log_pw, ENT_COMPAT, 'UTF-8'));
|
||||
|
||||
// gc- and nc-waypoints
|
||||
$wp_gc = isset($_POST['wp_gc']) ? $_POST['wp_gc'] : '';
|
||||
// fix #4356: gc waypoints are frequently copy&pasted with leading spaces
|
||||
$wp_gc = isset($_POST['wp_gc']) ? trim($_POST['wp_gc']) : '';
|
||||
tpl_set_var('wp_gc', htmlspecialchars($wp_gc, ENT_COMPAT, 'UTF-8'));
|
||||
|
||||
$wp_nc = isset($_POST['wp_nc']) ? $_POST['wp_nc'] : '';
|
||||
$wp_nc = isset($_POST['wp_nc']) ? trim($_POST['wp_nc']) : '';
|
||||
tpl_set_var('wp_nc', htmlspecialchars($wp_nc, ENT_COMPAT, 'UTF-8'));
|
||||
|
||||
//difficulty
|
||||
|
Reference in New Issue
Block a user