mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
path fixes and variable fixes
git-svn-id: http://www.observium.org/svn/observer/trunk@380 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
@ -5,7 +5,7 @@
|
||||
$interface['device_id'] = $device['device_id'];
|
||||
$interface['hostname'] = $device['hostname'];
|
||||
|
||||
if(!$_GET['type']) { $_GET['type'] = "bits"; }
|
||||
if(!$graph_type) { $graph_type = "bits"; }
|
||||
|
||||
$if_id = $interface['interface_id'];
|
||||
|
||||
@ -19,15 +19,12 @@
|
||||
$ifHardType = $interface['ifHardType'];
|
||||
|
||||
if($ifAlias) {$ifAlias = $ifAlias . "</br>";}
|
||||
if($bg == "#ffffff") { $bg = "#e5e5e5"; } else { $bg="#ffffff"; }
|
||||
if($bg == "#e5e5e5") { $bg = "#ffffff"; } else { $bg="#e5e5e5"; }
|
||||
|
||||
if($interface['in_errors'] > 0 || $interface['out_errors'] > 0) {
|
||||
$error_img = generateiflink($interface,"<img src='images/16/chart_curve_error.png' alt='Interface Errors' border=0>",errors);
|
||||
} else { $error_img = ""; }
|
||||
|
||||
# $graph_url = "graph.php?if=$if_id&from=$twoday&to=$now&width=400&height=120&type=bits";
|
||||
|
||||
|
||||
echo("<tr style=\"background-color: $bg; padding: 5px;\" valign=top onmouseover=\"this.style.backgroundColor='#fdd';\" onmouseout=\"this.style.backgroundColor='$bg';\" onclick=\"location.href='/device/".$device['device_id']."/'\" style='cursor: hand;'>
|
||||
<td valign=top width=300>");
|
||||
|
||||
@ -210,19 +207,19 @@ echo("</td>");
|
||||
// If we're showing graphs, generate the graph and print the img tags
|
||||
if($dographs && is_file($config['rrd_dir'] . "/" . $hostname . "/". $ifIndex . ".rrd")) {
|
||||
|
||||
$type = $_GET['type'];
|
||||
$type = $graph_type;
|
||||
|
||||
$daily_traffic = "graph.php?if=$if_id&type=" . $_GET['type'] . "&from=$day&to=$now&width=210&height=100";
|
||||
$daily_url = "graph.php?if=$if_id&type=" . $_GET['type'] . "&from=$day&to=$now&width=500&height=150";
|
||||
$daily_traffic = "graph.php?if=$if_id&type=" . $graph_type . "&from=$day&to=$now&width=210&height=100";
|
||||
$daily_url = "graph.php?if=$if_id&type=" . $graph_type . "&from=$day&to=$now&width=500&height=150";
|
||||
|
||||
$weekly_traffic = "graph.php?if=$if_id&type=" . $_GET['type'] . "&from=$week&to=$now&width=210&height=100";
|
||||
$weekly_url = "graph.php?if=$if_id&type=" . $_GET['type'] . "&from=$week&to=$now&width=500&height=150";
|
||||
$weekly_traffic = "graph.php?if=$if_id&type=" . $graph_type . "&from=$week&to=$now&width=210&height=100";
|
||||
$weekly_url = "graph.php?if=$if_id&type=" . $graph_type . "&from=$week&to=$now&width=500&height=150";
|
||||
|
||||
$monthly_traffic = "graph.php?if=$if_id&type=" . $_GET['type'] . "&from=$month&to=$now&width=210&height=100";
|
||||
$monthly_url = "graph.php?if=$if_id&type=" . $_GET['type'] . "&from=$month&to=$now&width=500&height=150";
|
||||
$monthly_traffic = "graph.php?if=$if_id&type=" . $graph_type . "&from=$month&to=$now&width=210&height=100";
|
||||
$monthly_url = "graph.php?if=$if_id&type=" . $graph_type . "&from=$month&to=$now&width=500&height=150";
|
||||
|
||||
$yearly_traffic = "graph.php?if=$if_id&type=" . $_GET['type'] . "&from=$year&to=$now&width=210&height=100";
|
||||
$yearly_url = "graph.php?if=$if_id&type=" . $_GET['type'] . "&from=$year&to=$now&width=500&height=150";
|
||||
$yearly_traffic = "graph.php?if=$if_id&type=" . $graph_type . "&from=$year&to=$now&width=210&height=100";
|
||||
$yearly_url = "graph.php?if=$if_id&type=" . $graph_type . "&from=$year&to=$now&width=500&height=150";
|
||||
|
||||
echo("<tr style='background-color: $bg; padding: 5px;'><td colspan=3>");
|
||||
|
||||
|
Reference in New Issue
Block a user