"; } } if($need_alert_display == true) { echo "
"; echo " "; echo $display_text; echo " | "; echo "
Do not make changes in the GUI until this is complete.") . "
"); } $pgtitle_output = true; ?>
"") { foreach($config['installedpackages']['menu'] as $menuitem) { if($menuitem['section'] != $section) continue; if($menuitem['url'] <> "") { $test_url=$menuitem['url']; $addresswithport = getenv("HTTP_HOST"); $colonpos = strpos($addresswithport, ":"); if ($colonpos !== False){ //my url is actually just the IP address of the pfsense box $myurl = substr($addresswithport, 0, $colonpos); } else { $myurl = $addresswithport; } $description = str_replace('$myurl', $myurl, $menuitem['url']); } else { $description = '/pkg.php?xml=' . $menuitem['configfile']; $test_url=$description; } if(isAllowedPage($test_url)){ $extarray[] = array($menuitem['name'], $description); } } } return $extarray; } function output_menu($arrayitem, $target = null) { foreach ($arrayitem as $item) { if (isAllowedPage($item[1]) || $item[1]=="/index.php?logout"){ $attr = sprintf("href=\"%s\"", htmlentities($item[1])); if ($target) { $attr .= sprintf(" target=\"%s\"", htmlentities($target)); } $class = "navlnk"; if ($item['class']) { $class .= " {$item['class']}"; } $attr .= sprintf(" class=\"%s\"", htmlentities($class)); if ($item['style']) { $attr .= sprintf(" style=\"%s\"", htmlentities($item['style'])); } echo "
"; echo " "; echo $display_text; echo " | "; echo "
"); } $pgtitle_output = true; ?>