diff --git a/html/includes/graphs/device/diskio_bits.inc.php b/html/includes/graphs/device/diskio_bits.inc.php
index ce36284fdd..4c6fce2b8f 100755
--- a/html/includes/graphs/device/diskio_bits.inc.php
+++ b/html/includes/graphs/device/diskio_bits.inc.php
@@ -29,6 +29,6 @@ $nototal = 1;
$rra_in = "read";
$rra_out = "written";
-include ("includes/graphs/generic_multi_bits_separated.inc.php");
+include("includes/graphs/generic_multi_bits_separated.inc.php");
?>
\ No newline at end of file
diff --git a/html/includes/graphs/device/diskio_ops.inc.php b/html/includes/graphs/device/diskio_ops.inc.php
index 82d2f10069..676a242f89 100755
--- a/html/includes/graphs/device/diskio_ops.inc.php
+++ b/html/includes/graphs/device/diskio_ops.inc.php
@@ -29,6 +29,6 @@ $colours_out = 'blues';
$nototal = 1;
-include ("includes/graphs/generic_multi_seperated.inc.php");
+include("includes/graphs/generic_multi_seperated.inc.php");
?>
\ No newline at end of file
diff --git a/html/includes/graphs/port/adsl_attainable.inc.php b/html/includes/graphs/port/adsl_attainable.inc.php
index a8e6eb0dbc..54c43d0196 100644
--- a/html/includes/graphs/port/adsl_attainable.inc.php
+++ b/html/includes/graphs/port/adsl_attainable.inc.php
@@ -22,7 +22,7 @@ $nototal = 1;
if ($rrd_list)
{
- include ("includes/graphs/generic_multi_line.inc.php");
+ include("includes/graphs/generic_multi_line.inc.php");
}
?>
\ No newline at end of file
diff --git a/html/includes/graphs/port/adsl_attenuation.inc.php b/html/includes/graphs/port/adsl_attenuation.inc.php
index 9ded419589..5b2cabafc5 100644
--- a/html/includes/graphs/port/adsl_attenuation.inc.php
+++ b/html/includes/graphs/port/adsl_attenuation.inc.php
@@ -22,7 +22,7 @@ $nototal = 1;
if ($rrd_list)
{
- include ("includes/graphs/generic_multi_line.inc.php");
+ include("includes/graphs/generic_multi_line.inc.php");
}
?>
\ No newline at end of file
diff --git a/html/includes/graphs/port/adsl_power.inc.php b/html/includes/graphs/port/adsl_power.inc.php
index 8385c59303..689025e65b 100644
--- a/html/includes/graphs/port/adsl_power.inc.php
+++ b/html/includes/graphs/port/adsl_power.inc.php
@@ -22,7 +22,7 @@ $nototal = 1;
if ($rrd_list)
{
- include ("includes/graphs/generic_multi_line.inc.php");
+ include("includes/graphs/generic_multi_line.inc.php");
}
?>
\ No newline at end of file
diff --git a/html/includes/graphs/port/adsl_snr.inc.php b/html/includes/graphs/port/adsl_snr.inc.php
index c55497807a..a8bf61db16 100644
--- a/html/includes/graphs/port/adsl_snr.inc.php
+++ b/html/includes/graphs/port/adsl_snr.inc.php
@@ -22,7 +22,7 @@ $nototal = 1;
if ($rrd_list)
{
- include ("includes/graphs/generic_multi_line.inc.php");
+ include("includes/graphs/generic_multi_line.inc.php");
}
?>
\ No newline at end of file
diff --git a/html/includes/graphs/port/adsl_speed.inc.php b/html/includes/graphs/port/adsl_speed.inc.php
index 6f8f72889e..81d951cedf 100644
--- a/html/includes/graphs/port/adsl_speed.inc.php
+++ b/html/includes/graphs/port/adsl_speed.inc.php
@@ -23,7 +23,7 @@ $nototal = 1;
if ($rrd_list)
{
- include ("includes/graphs/generic_multi_line.inc.php");
+ include("includes/graphs/generic_multi_line.inc.php");
}
?>
\ No newline at end of file
diff --git a/html/includes/graphs/port/nupkts.inc.php b/html/includes/graphs/port/nupkts.inc.php
index 389dbf8dd9..71a8c8bda6 100644
--- a/html/includes/graphs/port/nupkts.inc.php
+++ b/html/includes/graphs/port/nupkts.inc.php
@@ -36,7 +36,7 @@ if (1)
$nototal = 1;
- include ("includes/graphs/generic_multi_seperated.inc.php");
+ include("includes/graphs/generic_multi_seperated.inc.php");
}
elseif (is_file($config['rrd_dir'] . "/" . $device['hostname'] . "/" . safename($port['ifIndex'] . ".rrd")))
{
diff --git a/html/includes/graphs/port/pagp_bits.inc.php b/html/includes/graphs/port/pagp_bits.inc.php
index 1e45b14186..509917f4fd 100644
--- a/html/includes/graphs/port/pagp_bits.inc.php
+++ b/html/includes/graphs/port/pagp_bits.inc.php
@@ -25,6 +25,6 @@ $nototal = 1;
$rra_in = "INOCTETS";
$rra_out = "OUTOCTETS";
-include ("includes/graphs/generic_multi_bits_separated.inc.php");
+include("includes/graphs/generic_multi_bits_separated.inc.php");
?>
\ No newline at end of file
diff --git a/html/includes/graphs/screenos_sessions.inc.php b/html/includes/graphs/screenos_sessions.inc.php
index b79e285c6e..d19c600170 100644
--- a/html/includes/graphs/screenos_sessions.inc.php
+++ b/html/includes/graphs/screenos_sessions.inc.php
@@ -25,6 +25,6 @@ $nototal = 1;
$unit_text = "Sessions";
$scale_min = "0";
-include ("generic_multi_simplex_seperated.inc.php");
+include("generic_multi_simplex_seperated.inc.php");
?>
\ No newline at end of file
diff --git a/html/pages/device/events.inc.php b/html/pages/device/events.inc.php
index e40b101811..3e26133e40 100644
--- a/html/pages/device/events.inc.php
+++ b/html/pages/device/events.inc.php
@@ -6,7 +6,7 @@ echo('
');
while ($entry = mysql_fetch_array($data))
{
- include("includes/print-event.inc");
+ include("includes/print-event.inc.php");
}
echo('
');
diff --git a/html/pages/device/graphs.inc.php b/html/pages/device/graphs.inc.php
index f4907cf194..0ef1895ee9 100644
--- a/html/pages/device/graphs.inc.php
+++ b/html/pages/device/graphs.inc.php
@@ -52,7 +52,7 @@ foreach ($config['graph_types']['device'] as $graph => $entry)
{
$graph_title = $config['graph_types']['device'][$graph]['descr'];
$graph_type = "device_" . $graph;
- include ("includes/print-device-graph.php");
+ include("includes/print-device-graph.php");
}
}
diff --git a/html/pages/device/graphs/hrprocesses.inc.php b/html/pages/device/graphs/hrprocesses.inc.php
index 452d0dacbc..e1a286e86f 100644
--- a/html/pages/device/graphs/hrprocesses.inc.php
+++ b/html/pages/device/graphs/hrprocesses.inc.php
@@ -4,7 +4,7 @@ if (is_file($config['rrd_dir'] . "/" . $device['hostname'] ."/hrSystem.rrd"))
{
$graph_title = "Running Processes";
$graph_type = "device_hrprocesses";
- include ("includes/print-device-graph.php");
+ include("includes/print-device-graph.php");
}
?>
\ No newline at end of file
diff --git a/html/pages/device/graphs/uptime.inc.php b/html/pages/device/graphs/uptime.inc.php
index cea537e21b..c025b413c5 100644
--- a/html/pages/device/graphs/uptime.inc.php
+++ b/html/pages/device/graphs/uptime.inc.php
@@ -1,4 +1,8 @@
+
+$graph_title = "Device Uptime";
+$graph_type = "device_uptime";
+
+include("includes/print-device-graph.php");
+
+?>
\ No newline at end of file
diff --git a/html/pages/device/health.inc.php b/html/pages/device/health.inc.php
index ed6dbe9167..2273a8ebe4 100644
--- a/html/pages/device/health.inc.php
+++ b/html/pages/device/health.inc.php
@@ -69,7 +69,7 @@ if (is_file("pages/device/health/".mres($_GET['opta']).".inc.php"))
{
$graph_title = $type_text[$type];
$graph_type = "device_".$type;
- include ("includes/print-device-graph.php");
+ include("includes/print-device-graph.php");
}
}
}
diff --git a/html/pages/device/overview.inc.php b/html/pages/device/overview.inc.php
index d3a5d44e7c..3a37e85af2 100644
--- a/html/pages/device/overview.inc.php
+++ b/html/pages/device/overview.inc.php
@@ -68,7 +68,7 @@ if (mysql_affected_rows() > "0")
echo("");
echo("
Recent Syslog
");
echo("
");
- while ($entry = mysql_fetch_array($query)) { include("includes/print-syslog.inc"); }
+ while ($entry = mysql_fetch_array($query)) { include("includes/print-syslog.inc.php"); }
echo("
");
echo("
");
}
@@ -101,7 +101,7 @@ echo("");
while ($entry = mysql_fetch_array($data))
{
- include("includes/print-event-short.inc");
+ include("includes/print-event-short.inc.php");
}
echo("
");
diff --git a/html/pages/device/srv.inc.php b/html/pages/device/srv.inc.php
index 3d9ec7d2b7..8167a644a3 100644
--- a/html/pages/device/srv.inc.php
+++ b/html/pages/device/srv.inc.php
@@ -7,7 +7,7 @@ if (mysql_result(mysql_query("select count(service_id) from services WHERE devic
$service_query = mysql_query("select * from services WHERE device_id = '".$device['device_id']."' ORDER BY service_type");
while ($service = mysql_fetch_array($service_query))
{
- include("includes/print-service.inc");
+ include("includes/print-service.inc.php");
}
echo("");
diff --git a/html/pages/device/syslog.inc.php b/html/pages/device/syslog.inc.php
index 83ea150419..3d18033ead 100644
--- a/html/pages/device/syslog.inc.php
+++ b/html/pages/device/syslog.inc.php
@@ -43,7 +43,7 @@ $sql = "SELECT *, DATE_FORMAT(timestamp, '%D %b %T') AS date from syslog WHERE
$sql .= " ORDER BY timestamp DESC LIMIT 1000";
$query = mysql_query($sql);
echo("");
-while ($entry = mysql_fetch_array($query)) { include("includes/print-syslog.inc"); }
+while ($entry = mysql_fetch_array($query)) { include("includes/print-syslog.inc.php"); }
echo("
");
?>
\ No newline at end of file
diff --git a/html/pages/device/toner.inc.php b/html/pages/device/toner.inc.php
index b8f83de260..904c12db9f 100644
--- a/html/pages/device/toner.inc.php
+++ b/html/pages/device/toner.inc.php
@@ -2,7 +2,7 @@
$graph_title = "Toner";
$graph_type = "device_toner";
-include ("includes/print-device-graph.php");
+include("includes/print-device-graph.php");
?>
diff --git a/html/pages/device/vrfs.inc.php b/html/pages/device/vrfs.inc.php
index ae7ffa0f3b..46277c1a04 100644
--- a/html/pages/device/vrfs.inc.php
+++ b/html/pages/device/vrfs.inc.php
@@ -16,7 +16,7 @@ $i = "0";
$vrf_query = mysql_query("select * from vrfs WHERE device_id = '".$_GET['id']."' ORDER BY 'vrf_name'");
while ($vrf = mysql_fetch_array($vrf_query))
{
- include("includes/print-vrf.inc");
+ include("includes/print-vrf.inc.php");
$i++;
}
diff --git a/html/pages/eventlog.inc.php b/html/pages/eventlog.inc.php
index 64047a98ec..e6696df998 100644
--- a/html/pages/eventlog.inc.php
+++ b/html/pages/eventlog.inc.php
@@ -15,7 +15,7 @@ echo('');
while ($entry = mysql_fetch_array($data))
{
- include("includes/print-event.inc");
+ include("includes/print-event.inc.php");
}
echo("
");
diff --git a/html/pages/front/default.php b/html/pages/front/default.php
index b8a01fe8be..46cba2144c 100644
--- a/html/pages/front/default.php
+++ b/html/pages/front/default.php
@@ -102,7 +102,7 @@ if ($config['enable_syslog'])
echo("");
while ($entry = mysql_fetch_array($query)) {
$entry = array_merge($entry, device_by_id_cache($entry['device_id']));
- include("includes/print-syslog.inc");
+ include("includes/print-syslog.inc.php");
}
echo("
");
@@ -128,7 +128,7 @@ $data = mysql_query($query);
echo("");
while ($entry = mysql_fetch_array($data)) {
- include("includes/print-event.inc");
+ include("includes/print-event.inc.php");
}
echo("
");
diff --git a/html/pages/front/demo.php b/html/pages/front/demo.php
index ea09176dbd..8c5a90eed9 100644
--- a/html/pages/front/demo.php
+++ b/html/pages/front/demo.php
@@ -99,7 +99,7 @@ echo("");
while ($entry = mysql_fetch_array($query))
{
$entry = array_merge($entry, device_by_id_cache($entry['device_id']));
- include("includes/print-syslog.inc");
+ include("includes/print-syslog.inc.php");
}
echo("
");
diff --git a/html/pages/front/example2.php b/html/pages/front/example2.php
index 669e5931da..3e2db41d3e 100644
--- a/html/pages/front/example2.php
+++ b/html/pages/front/example2.php
@@ -96,7 +96,7 @@ echo("
$sql = "SELECT *, DATE_FORMAT(timestamp, '%D %b %T') AS date from syslog ORDER BY timestamp DESC LIMIT 20";
$query = mysql_query($sql);
echo("");
-while ($entry = mysql_fetch_array($query)) { include("includes/print-syslog.inc"); }
+while ($entry = mysql_fetch_array($query)) { include("includes/print-syslog.inc.php"); }
echo("
");
diff --git a/html/pages/front/jt.php b/html/pages/front/jt.php
index 9157ddc0d7..0d9372010a 100644
--- a/html/pages/front/jt.php
+++ b/html/pages/front/jt.php
@@ -96,7 +96,7 @@ echo("
$sql = "SELECT *, DATE_FORMAT(timestamp, '%D %b %T') AS date from syslog,devices WHERE syslog.device_id = devices.device_id ORDER BY seq DESC LIMIT 20";
$query = mysql_query($sql);
echo("");
-while ($entry = mysql_fetch_array($query)) { include("includes/print-syslog.inc"); }
+while ($entry = mysql_fetch_array($query)) { include("includes/print-syslog.inc.php"); }
echo("
");
diff --git a/html/pages/services.inc.php b/html/pages/services.inc.php
index 9f56b80c05..e81bca24f6 100644
--- a/html/pages/services.inc.php
+++ b/html/pages/services.inc.php
@@ -26,7 +26,7 @@ if ($_SESSION['userlevel'] >= '5')
$service_query = mysql_query("SELECT * FROM `services` WHERE `device_id` = '" . $host_data['device_id'] . "' $where");
while ($service = mysql_fetch_array($service_query))
{
- include("includes/print-service.inc");
+ include("includes/print-service.inc.php");
# $samehost = 1;
if ($_GET['opta'] == "details")
{
diff --git a/html/pages/syslog.inc.php b/html/pages/syslog.inc.php
index 7e3b239408..81fcca6fea 100644
--- a/html/pages/syslog.inc.php
+++ b/html/pages/syslog.inc.php
@@ -47,19 +47,23 @@
print_optionbar_end();
-if ($_POST['string']) {
+if ($_POST['string'])
+{
$where = " AND S.msg LIKE '%".$_POST['string']."%'";
}
-if ($_POST['program']) {
+if ($_POST['program'])
+{
$where .= " AND S.program = '".$_POST['program']."'";
}
-if ($_POST['device']) {
+if ($_POST['device'])
+{
$where .= " AND D.device_id = '".$_POST['device']."'";
}
-if ($_SESSION['userlevel'] >= '5') {
+if ($_SESSION['userlevel'] >= '5')
+{
$sql = "SELECT *, DATE_FORMAT(timestamp, '%D %b %T') AS date from syslog
WHERE 1 $where ORDER BY timestamp DESC LIMIT 1000";
} else {
@@ -69,9 +73,10 @@ if ($_SESSION['userlevel'] >= '5') {
$query = mysql_query($sql);
echo("");
-while ($entry = mysql_fetch_array($query)) {
+while ($entry = mysql_fetch_array($query))
+{
$entry = array_merge($entry, device_by_id_cache($entry['device_id']));
- include("includes/print-syslog.inc");
+ include("includes/print-syslog.inc.php");
}
echo("
");