[Mapbender-commits] r3431 - branches/beck_dev/http/php

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Tue Jan 13 03:40:25 EST 2009


Author: beck
Date: 2009-01-13 03:40:25 -0500 (Tue, 13 Jan 2009)
New Revision: 3431

Modified:
   branches/beck_dev/http/php/mb_listGUIs.php
Log:


Modified: branches/beck_dev/http/php/mb_listGUIs.php
===================================================================
--- branches/beck_dev/http/php/mb_listGUIs.php	2009-01-13 08:40:03 UTC (rev 3430)
+++ branches/beck_dev/http/php/mb_listGUIs.php	2009-01-13 08:40:25 UTC (rev 3431)
@@ -55,6 +55,7 @@
 	echo "<h1>Available GUIs</h1>";
 	printf("<p><a href=\"../php/mod_logout.php?%s\"><img src=\"../img/button_gray/logout_off.png\" onmouseover=\"this.src='../img/button_gray/logout_over.png'\" onmouseout=\"this.src='../img/button_gray/logout_off.png'\" title=\"Logout\"></a></p>",SID);
 	
+	$total_guis = 0;
 	while($row = db_fetch_array($result)){
 		if($category !== $row["category_name"]) {
 			$category = $row["category_name"];
@@ -71,8 +72,11 @@
 			echo "<ul class=\"gui_list\">";
 		}
 		
-		$url = sprintf("index.php?%s&gui_id=%s",strip_tags(SID),$row["gui_id"]);
-		printf("<li onclick=\"location.href='%s'\"><strong><a href=\"%s\">%s</a></strong><br /><em>%s</em></li>",$url,$url,$row["gui_name"],$row["gui_description"]);
+		$class = ($total_guis %2 === 0) ? " class=\"alternate\"" : NULL;
+		$url   = sprintf("index.php?%s&gui_id=%s",strip_tags(SID),$row["gui_id"]);
+		printf("<li%s onclick=\"location.href='%s'\"><strong><a href=\"%s\">%s</a></strong><br /><em>%s</em></li>",$class,$url,$url,$row["gui_name"],$row["gui_description"]);
+		
+		$total_guis++;
 	}
 }
 ?>
\ No newline at end of file



More information about the Mapbender_commits mailing list