fix array index

This commit is contained in:
Bruno Rybársky 2024-01-16 20:56:37 +01:00
parent 8190a9ad01
commit 39dc3b72bb

@ -5,12 +5,12 @@ function generateNavigation()
global $routerConfig;
global $routerRequest;
$site_dirs = array_diff(scandir($routerConfig["static_page_dir"]), array('.', '..'));
$site_dirs = array_diff(scandir($routerConfig["page_dir"]), array('.', '..'));
$nav_out = "";
foreach ($site_dirs as $site_dir) {
$pages_dir = array_diff(scandir($routerConfig["static_page_dir"] . $site_dir), array('.', '..'));
$pages_dir = array_diff(scandir($routerConfig["page_dir"] . $site_dir), array('.', '..'));
$site_name = str_replace("_", " ", $site_dir);
if ($site_name == "global") {