diff options
author | dweller <dweller@cabin.digital> | 2024-02-26 19:58:13 +0200 |
---|---|---|
committer | dweller <dweller@cabin.digital> | 2024-02-26 19:58:13 +0200 |
commit | cd0894ddefbc9c0be2d59b9160fc911e16b67bd2 (patch) | |
tree | 8fca4a84f8b20bc3c2ee21ef7a8ffd919d6f2a1e /common.php | |
parent | 04308eeded8a6b90879e5d413b181ac144268901 (diff) |
remove unnecessary urldecode from common query args, PHP does it for me, fixes apropos links with non-alphanum chars
Diffstat (limited to '')
-rw-r--r-- | common.php | 16 |
1 files changed, 13 insertions, 3 deletions
@@ -10,7 +10,17 @@ $root = (!empty($_SERVER['HTTPS']) ? 'https' : 'http') . '://' . $_SERVER['HTTP_HOST']; $manpath = "/usr/share/man"; - $action = trim(urldecode($_GET['action'] ?? null)); - $query = trim(urldecode($_GET['query'] ?? null)); - $section = trim(urldecode($_GET['section'] ?? null)); + $action = trim($_GET['action'] ?? null); + $query = trim($_GET['query'] ?? null); + $section = trim($_GET['section'] ?? null); + + + /* + function dbg_print($data) + { + $output = $data; + if(is_array($output)) $output = implode(',', $output); + echo "<script>console.log('srv => " . $output . "' );</script>"; + } + */ ?> |