"") { foreach($config['installedpackages']['menu'] as $menuitem) { if($menuitem['section'] != $section) continue; if($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']; } $htmltext .= '
  • ' . $menuitem['name'] . '
  • ' . "\n"; } } return $htmltext; } /* NOTICE ACKNOWLEDGE CODE by Erik Kristensen */ if ($_REQUEST['noticeaction'] == 'acknowledge') { $notice_id = $_REQUEST['noticeid']; close_notice($notice_id); } /**********************************************/ ?>