]> jfr.im git - irc/unrealircd/unrealircd-webpanel.git/commitdiff
Try to fix active nav item highlighting
authorValerie Pond <redacted>
Sun, 15 Jan 2023 21:39:11 +0000 (21:39 +0000)
committerValerie Pond <redacted>
Sun, 15 Jan 2023 21:39:11 +0000 (21:39 +0000)
header.php

index 8f0b7a4bb31c687f790cce2cfb4fbe928c8a493f..ebc4c1cfed60544c88d22381cbf179d7eb31739f 100644 (file)
@@ -34,7 +34,7 @@ $active_page = NULL;
 foreach ($pages as $name => $page)
 {
        $script = $_SERVER['SCRIPT_FILENAME'];
-       if (str_ends_with($script, BASE_URL . "index.php") || !strlen($page))
+       if ((str_ends_with($script, BASE_URL . "index.php") && BASE_URL != "/") || !strlen($page))
        {
                $active_page = "";
        }