Profiler/Tooltips

* do not transform page parameters to lowercase. The tooltip Javascript expects the server response in the same case it got sent.
 * transform to lowercase just for lookups
 * fixes #394
This commit is contained in:
Sarjuuk
2024-07-04 16:23:46 +02:00
parent c3347b8e9c
commit 02e33b4038
2 changed files with 3 additions and 3 deletions

View File

@@ -237,9 +237,9 @@ if (!CLI)
Lang::load(User::$localeId); Lang::load(User::$localeId);
// parse page-parameters .. sanitize before use! // parse page-parameters .. sanitize before use!
$str = explode('&', mb_strtolower($_SERVER['QUERY_STRING'] ?? ''), 2)[0]; $str = explode('&', $_SERVER['QUERY_STRING'] ?? '', 2)[0];
$_ = explode('=', $str, 2); $_ = explode('=', $str, 2);
$pageCall = $_[0]; $pageCall = mb_strtolower($_[0]);
$pageParam = $_[1] ?? ''; $pageParam = $_[1] ?? '';
} }
else if (DB::isConnected(DB_AOWOW)) else if (DB::isConnected(DB_AOWOW))

View File

@@ -113,7 +113,7 @@ trait TrProfiler
// cat[0] is always region // cat[0] is always region
// cat[1] is realm or bGroup (must be realm if cat[2] is set) // cat[1] is realm or bGroup (must be realm if cat[2] is set)
// cat[2] is arena-team, guild or player // cat[2] is arena-team, guild or player
$cat = explode('.', $pageParam, 3); $cat = explode('.', mb_strtolower($pageParam), 3);
$cat = array_map('urldecode', $cat); $cat = array_map('urldecode', $cat);