Tidy up "status_rrd_graph.php" XHTML

"id" attributes cannot start with a numeric character, so change "8hour"
to "eighthour" and "4year" to "fouryear".
This commit is contained in:
Colin Fleming 2014-09-14 13:17:38 +01:00
parent 62424bdbbb
commit d02491e632

View File

@ -245,16 +245,16 @@ foreach($databases as $database) {
$ui_databases = array_merge($dbheader, $databases);
$custom_databases = array_merge($dbheader_custom, $databases);
$graphs = array("8hour", "day", "week", "month", "quarter", "year", "4year");
$graphs = array("eighthour", "day", "week", "month", "quarter", "year", "fouryear");
$periods = array("absolute" => gettext("Absolute Timespans"), "current" => gettext("Current Period"), "previous" => gettext("Previous Period"));
$graph_length = array(
"8hour" => 28800,
"eighthour" => 28800,
"day" => 86400,
"week" => 604800,
"month" => 2678400,
"quarter" => 7948800,
"year" => 31622400,
"4year" => 126230400);
"fouryear" => 126230400);
$pgtitle = array(gettext("Status"),gettext("RRD Graphs"));
@ -331,7 +331,7 @@ function get_dates($curperiod, $graph) {
$offset = 0;
}
switch($graph) {
case "8hour":
case "eighthour":
if($curhour < 24)
$starthour = 16;
if($curhour < 16)
@ -385,7 +385,7 @@ function get_dates($curperiod, $graph) {
if($offset != 0)
$end = mktime(0, 0, 0, 1, 0, (($curyear + $offset) +1));
break;
case "4year":
case "fouryear":
$start = mktime(0, 0, 0, 1, 0, (($curyear - 3) + $offset));
if($offset != 0)
$end = mktime(0, 0, 0, 1, 0, (($curyear + $offset) +1));