Handle error on top page

Signed-off-by: Michal Čihař <michal@cihar.com>
This commit is contained in:
Michal Čihař 2014-06-24 09:05:00 +02:00
parent 60211dd027
commit 2cc58f0847

View File

@ -156,7 +156,11 @@ function PMA_sanitizeUrl($url)
// get script name
preg_match("<([a-zA-Z\-_\d]*\.php)$>", $components["path"], $matches);
$script_name = $matches[1];
if (count($matches)) < 2) {
$script_name = 'index.php';
} else {
$script_name = $matches[1];
}
// remove deployment specific details to make uri more generic
parse_str($components["query"], $query_array);