From 055871bb1ac4378212acd797f96dc1a62c0631ef Mon Sep 17 00:00:00 2001 From: Edmondo Tommasina Date: Wed, 19 May 2010 14:59:45 +0200 Subject: Define alternating odd/even css classes for rows in main summary To select different background colors for the rows in the main summary page, just uncomment the tr.odd/tr.even background definition in layout/style.css and set the color. --- inc/html.inc.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'inc/html.inc.php') diff --git a/inc/html.inc.php b/inc/html.inc.php index a05aab6..ada8d99 100644 --- a/inc/html.inc.php +++ b/inc/html.inc.php @@ -66,8 +66,14 @@ function host_summary($hosts) { echo "\n"; + $row_style = array(0 => "even", 1 => "odd"); + $host_counter = 0; + foreach($hosts as $host) { - printf('', + $host_counter++; + + printf('', $row_style[$host_counter % 2]); + printf('', $CONFIG['weburl'],$host, $host); if ($CONFIG['showload']) { -- cgit v1.1
%s
%s