diff --git a/html/pages/device.inc.php b/html/pages/device.inc.php index 4a3af577e1..2e8f801c78 100644 --- a/html/pages/device.inc.php +++ b/html/pages/device.inc.php @@ -37,14 +37,14 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) { echo('
  • - + Overview
  • '); } echo('
  • - + Graphs
  • '); @@ -58,7 +58,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if ($health) { echo('
  • - + Health
  • '); @@ -67,7 +67,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if (@mysql_result(mysql_query("select count(app_id) from applications WHERE device_id = '" . $device['device_id'] . "'"), 0) > '0') { echo('
  • - + Apps
  • '); @@ -76,7 +76,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if (is_dir($config['collectd_dir'] . "/" . $device['hostname'] ."/")) { echo('
  • - + CollectD
  • '); @@ -85,7 +85,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if (@mysql_result(mysql_query("select count(interface_id) from ports WHERE device_id = '" . $device['device_id'] . "'"), 0) > '0') { echo('
  • - + Ports
  • '); @@ -94,7 +94,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if (@mysql_result(mysql_query("select count(vlan_id) from vlans WHERE device_id = '" . $device['device_id'] . "'"), 0) > '0') { echo('
  • - + VLANs
  • '); @@ -103,7 +103,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if (@mysql_result(mysql_query("SELECT COUNT(id) FROM vminfo WHERE device_id = '" . $device["device_id"] . "'"), 0) > '0') { echo('
  • - + Virtual Machines
  • '); @@ -112,7 +112,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if (@mysql_result(mysql_query("select count(*) from vrfs WHERE device_id = '" . $device['device_id'] . "'"), 0) > '0') { echo('
  • - + VRFs
  • '); @@ -121,7 +121,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if ($config['enable_bgp'] && $device['bgpLocalAs']) { echo('
  • - + BGP
  • '); @@ -133,7 +133,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if ($cef_count) { echo('
  • - + CEF
  • '); @@ -142,7 +142,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if ($_SESSION['userlevel'] >= "5" && mysql_result(mysql_query("SELECT count(*) FROM links AS L, ports AS I WHERE I.device_id = '".$device['device_id']."' AND I.interface_id = L.local_interface_id"),0)) { echo('
  • - + Map
  • '); @@ -151,7 +151,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if ($config['enable_inventory'] && @mysql_result(mysql_query("SELECT * FROM `entPhysical` WHERE device_id = '".$device['device_id']."'"), 0) > '0') { echo('
  • - + Inventory
  • '); @@ -159,7 +159,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) elseif (device_permitted($device['device_id']) && $config['enable_inventory'] && @mysql_result(mysql_query("SELECT * FROM `hrDevice` WHERE device_id = '".$device['device_id']."'"), 0) > '0') { echo('
  • - + Inventory
  • '); @@ -168,7 +168,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if (mysql_result(mysql_query("select count(service_id) from services WHERE device_id = '" . $device['device_id'] . "'"), 0) > '0') { echo('
  • - + Services
  • '); @@ -177,7 +177,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if (@mysql_result(mysql_query("select count(toner_id) from toner WHERE device_id = '" . $device['device_id'] . "'"), 0) > '0') { echo('
  • - + Toner
  • '); @@ -186,7 +186,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if (device_permitted($device['device_id'])) { echo('
  • - + Events
  • '); @@ -195,7 +195,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if ($config['enable_syslog']) { echo('
  • - + Syslog
  • '); @@ -214,7 +214,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if ($device_config_file) { echo('
  • - + Config
  • '); @@ -237,7 +237,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if ($nfsen_rrd_file) { echo('
  • - + Netflow
  • '); @@ -247,7 +247,7 @@ if (device_permitted($_GET['id']) || $check_device == $_GET['id']) if ($_SESSION['userlevel'] >= "7") { echo('
  • - + Settings
  • '); diff --git a/html/pages/device/health/mempool.inc.php b/html/pages/device/health/mempool.inc.php index 440a967634..f54a1f6f29 100644 --- a/html/pages/device/health/mempool.inc.php +++ b/html/pages/device/health/mempool.inc.php @@ -14,7 +14,7 @@ while ($mempool = mysql_fetch_assoc($mempools)) $text_descr = rewrite_entity_descr($mempool['mempool_descr']); - $mempool_url = "device/".$device['device_id']."/health/memory/"; + $mempool_url = "device/".$device['device_id']."/health/mempool/"; $mini_url = "graph.php?id=".$mempool['mempool_id']."&type=".$graph_type."&from=".$day."&to=".$now."&width=80&height=20&bg=f4f4f4"; $mempool_popup = "onmouseover=\"return overlib('
    ".$device['hostname']." - ".$text_descr; diff --git a/html/pages/device/health/processor.inc.php b/html/pages/device/health/processor.inc.php index c414acbe62..4cd23b163c 100644 --- a/html/pages/device/health/processor.inc.php +++ b/html/pages/device/health/processor.inc.php @@ -9,7 +9,7 @@ $i = '1'; $procs = mysql_query("SELECT * FROM `processors` WHERE device_id = '" . $device['device_id'] . "'"); while ($proc = mysql_fetch_assoc($procs)) { - $proc_url = "device/".$device['device_id']."/health/processors/"; + $proc_url = "device/".$device['device_id']."/health/processor/"; $mini_url = "graph.php?id=".$proc['processor_id']."&type=".$graph_type."&from=".$day."&to=".$now."&width=80&height=20&bg=f4f4f4"; diff --git a/html/pages/device/hrdevice.inc.php b/html/pages/device/hrdevice.inc.php index c3de1e9ff5..f09c7cd498 100644 --- a/html/pages/device/hrdevice.inc.php +++ b/html/pages/device/hrdevice.inc.php @@ -1,17 +1,17 @@ "); +echo(''); $hrdevices = mysql_query("SELECT * FROM `hrDevice` WHERE `device_id` = '".$device['device_id']."' ORDER BY `hrDeviceIndex`"); + while ($hrdevice = mysql_fetch_assoc($hrdevices)) { - echo(""); if ($hrdevice['hrDeviceType'] == "hrDeviceProcessor") { $proc_id = mysql_result(mysql_query("SELECT processor_id FROM processors WHERE device_id = '".$device['device_id']."' AND hrDeviceIndex = '".$hrdevice['hrDeviceIndex']."'"),0); - $proc_url = $config['base_url'] . "/device/".$device['device_id']."/health/processors/"; + $proc_url = "device/".$device['device_id']."/health/processor/"; $proc_popup = "onmouseover=\"return overlib('
    ".$device['hostname']." - ".$hrdevice['hrDeviceDescr']; $proc_popup .= "
    "; $proc_popup .= "', RIGHT".$config['overlib_defaults'].");\" onmouseout=\"return nd();\""; @@ -28,7 +28,9 @@ while ($hrdevice = mysql_fetch_assoc($hrdevices)) $mini_graph = overlib_link($_SERVER['REQUEST_URI'], generate_graph_tag($graph_array), generate_graph_tag($graph_array_zoom), NULL); echo(''); - } elseif ($hrdevice['hrDeviceType'] == "hrDeviceNetwork") { + } + elseif ($hrdevice['hrDeviceType'] == "hrDeviceNetwork") + { $int = str_replace("network interface ", "", $hrdevice['hrDeviceDescr']); $interface = mysql_fetch_assoc(mysql_query("SELECT * FROM ports WHERE device_id = '".$device['device_id']."' AND ifDescr = '".$int."'")); if ($interface['ifIndex']) @@ -58,9 +60,8 @@ while ($hrdevice = mysql_fetch_assoc($hrdevices)) echo(""); echo(""); echo(""); - } -echo("
    ".$hrdevice['hrDeviceIndex']."'.$mini_graph.'".$hrdevice['hrDeviceType']."".$hrdevice['hrDeviceStatus']."".$hrdevice['hrDeviceErrors']."".$hrdevice['hrProcessorLoad']."
    "); +echo(''); ?> \ No newline at end of file diff --git a/html/pages/device/overview/mempools.inc.php b/html/pages/device/overview/mempools.inc.php index 210c875f6e..01b2a16d7a 100644 --- a/html/pages/device/overview/mempools.inc.php +++ b/html/pages/device/overview/mempools.inc.php @@ -6,7 +6,7 @@ if (mysql_result(mysql_query("SELECT count(*) from mempools WHERE device_id = '" { echo("
    "); echo("

    "); - echo(''); + echo(''); echo(" Memory Pools

    "); echo(""); $mempool_rows = '0'; diff --git a/html/pages/device/overview/processors.inc.php b/html/pages/device/overview/processors.inc.php index 75ec594854..e3a99790ea 100644 --- a/html/pages/device/overview/processors.inc.php +++ b/html/pages/device/overview/processors.inc.php @@ -7,7 +7,7 @@ if (mysql_result(mysql_query("SELECT count(*) from processors WHERE device_id = $processor_rows = 0; echo("
    "); echo("

    "); - echo(''); + echo(''); echo(" Processors

    "); echo("
    "); $procs = mysql_query("SELECT * FROM `processors` WHERE device_id = '" . $device['device_id'] . "' ORDER BY processor_descr ASC"); diff --git a/html/pages/health.inc.php b/html/pages/health.inc.php index 52b3984d0b..2495acb737 100644 --- a/html/pages/health.inc.php +++ b/html/pages/health.inc.php @@ -29,9 +29,9 @@ foreach ($datas as $texttype) echo(""); } - echo('' . $type_text[$type] .""); + echo('' . $type_text[$type] .''); - if ($_GET['opta'] == $type) { echo(""); } + if ($_GET['opta'] == $type) { echo(""); } $sep = ' | '; } diff --git a/html/pages/health/mempool.inc.php b/html/pages/health/mempool.inc.php index a1d4b225eb..5fdf58a741 100644 --- a/html/pages/health/mempool.inc.php +++ b/html/pages/health/mempool.inc.php @@ -21,11 +21,9 @@ while ($mempool = mysql_fetch_assoc($mempools)) { if (!is_integer($i/2)) { $row_colour = $list_colour_a; } else { $row_colour = $list_colour_b; } - $proc_url = "?page=device/".$device['device_id']."/health/memory/"; - $text_descr = $mempool['mempool_descr']; - $mempool_url = "/device/".$mempool['device_id']."/health/memory/"; + $mempool_url = "device/".$mempool['device_id']."/health/mempool/"; $mini_url = $config['base_url'] . "/graph.php?id=".$mempool['mempool_id']."&type=".$graph_type."&from=".$day."&to=".$now."&width=80&height=20&bg=f4f4f4"; $mempool_popup = "onmouseover=\"return overlib('
    ".$device['hostname']." - ".$text_descr; diff --git a/html/pages/health/processor.inc.php b/html/pages/health/processor.inc.php index fe61bced26..3a64b1a667 100644 --- a/html/pages/health/processor.inc.php +++ b/html/pages/health/processor.inc.php @@ -29,7 +29,7 @@ while ($proc = mysql_fetch_assoc($procs)) $text_descr = str_replace("Sub-Module", "Module ", $text_descr); $text_descr = str_replace("DFC Card", "DFC", $text_descr); - $proc_url = "/device/".$device['device_id']."/health/processors/"; + $proc_url = "device/".$device['device_id']."/health/processor/"; $mini_url = $config['base_url'] . "/graph.php?id=".$proc['processor_id']."&type=".$graph_type."&from=".$day."&to=".$now."&width=80&height=20&bg=f4f4f4";