diff --git a/html/includes/graphs/generic_multi_simplex_seperated.inc.php b/html/includes/graphs/generic_multi_simplex_seperated.inc.php index d8d332497..96026078e 100644 --- a/html/includes/graphs/generic_multi_simplex_seperated.inc.php +++ b/html/includes/graphs/generic_multi_simplex_seperated.inc.php @@ -2,21 +2,18 @@ include("common.inc.php"); - $i = 0; - $rrd_options .= " COMMENT:' In\: Current Maximum '"; + $unit_text = str_pad(truncate($unit_text,10),10); + $rrd_options .= " COMMENT:'$unit_text Cur Max'"; if(!$nototal) {$rrd_options .= " COMMENT:'Total '";} - $rrd_options .= " COMMENT:'Out\: Current Maximum'"; - if(!$nototal) {$rrd_options .= " COMMENT:' Total'";} - $rrd_options .= " COMMENT:'\\\\n'"; + $rrd_options .= " COMMENT:'\\n'"; + $i = 0; foreach($rrd_list as $rrd) { if(!$config['graph_colours'][$colours][$iter]) { $iter = 0; } $colour=$config['graph_colours'][$colours][$iter]; $rrd_options .= " DEF:".$rrd['rra'].$i."=".$rrd['filename'].":".$rrd['rra'].":AVERAGE "; $rrd_options .= " DEF:".$rrd['rra'].$i."max=".$rrd['filename'].":".$rrd['rra'].":MAX "; - #echo("

DEF:".$rrd['rra'].$i."=".$rrd['filename'].":".$rrd['rra'].":AVERAGE

"); - if(!$args['nototal']) { $rrd_options .= " VDEF:tot".$rrd['rra'].$i."=".$rrd['rra'].$i.",TOTAL"; } @@ -25,7 +22,7 @@ $rrd_options .= " GPRINT:".$rrd['rra'].$i.":LAST:%6.2lf%s$units"; $rrd_options .= " GPRINT:".$rrd['rra'].$i."max:MAX:%6.2lf%s$units"; if(!$nototal) { $rrd_options .= " GPRINT:tot".$rrd['rra'].$i.":%6.2lf%s$total_units"; } - $rrd_options .= " COMMENT:\\\\n"; + $rrd_options .= " COMMENT:'\\n'"; $i++; $iter++; } diff --git a/html/includes/graphs/generic_simplex.inc.php b/html/includes/graphs/generic_simplex.inc.php index 412af42c4..549dc4639 100644 --- a/html/includes/graphs/generic_simplex.inc.php +++ b/html/includes/graphs/generic_simplex.inc.php @@ -24,7 +24,7 @@ if($graph_max) { $rrd_options .= " AREA:".$rra."#".$colour_area.":"; $rrd_options .= " COMMENT:'".$unit_text."Now Ave Max"; if($percentile) { - $rrd_options .= "\ \ \ \ \ \ ".$percentile."th\ %"; + $rrd_options .= " ".$percentile."th %"; } $rrd_options .= "\\n'"; $rrd_options .= " LINE1.25:".$rra."#".$colour_line.":In\ "; diff --git a/html/includes/graphs/port_errors.inc.php b/html/includes/graphs/port_errors.inc.php index c3357b982..02b336bf5 100644 --- a/html/includes/graphs/port_errors.inc.php +++ b/html/includes/graphs/port_errors.inc.php @@ -26,7 +26,7 @@ $colour_area_out_max = "FF9966"; $graph_max = 1; -$unit_text = "Errors\ "; +$unit_text = "Errors"; include("generic_duplex.inc.php"); diff --git a/html/includes/graphs/port_etherlike.inc.php b/html/includes/graphs/port_etherlike.inc.php index b4763ed83..18a658608 100644 --- a/html/includes/graphs/port_etherlike.inc.php +++ b/html/includes/graphs/port_etherlike.inc.php @@ -24,9 +24,9 @@ if(is_file($config['rrd_dir'] . "/" . $port['hostname'] . "/etherlike-" . $port[ } } -$colours = 'mixed'; - -$nototal = 1; +$colours = "mixed"; +$nototal = 1; +$unit_text = "Errors"; include ("generic_multi_simplex_seperated.inc.php");