[Mapbender-commits] r3104 - in branches: nimix_dev/http/html tree_dev/http/html

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Fri Oct 3 08:12:10 EDT 2008


Author: nimix
Date: 2008-10-03 08:12:10 -0400 (Fri, 03 Oct 2008)
New Revision: 3104

Modified:
   branches/nimix_dev/http/html/mod_treefolder2.php
   branches/tree_dev/http/html/mod_treefolder2.php
Log:
fix initialisation with IE

Modified: branches/nimix_dev/http/html/mod_treefolder2.php
===================================================================
--- branches/nimix_dev/http/html/mod_treefolder2.php	2008-10-03 12:08:23 UTC (rev 3103)
+++ branches/nimix_dev/http/html/mod_treefolder2.php	2008-10-03 12:12:10 UTC (rev 3104)
@@ -77,7 +77,7 @@
 var treeState = "";
 <?php
 //load structure
-$sql = "SELECT * FROM gui_treegde WHERE fkey_gui_id = $1 ORDER BY lft;";
+$sql = "SELECT * FROM gui_treegde WHERE fkey_gui_id = $1 AND NOT lft = 1 ORDER BY lft;";
 $v = array($_SESSION["mb_user_gui"]);
 $t = array("s");
 $res = db_prep_query($sql, $v, $t);

Modified: branches/tree_dev/http/html/mod_treefolder2.php
===================================================================
--- branches/tree_dev/http/html/mod_treefolder2.php	2008-10-03 12:08:23 UTC (rev 3103)
+++ branches/tree_dev/http/html/mod_treefolder2.php	2008-10-03 12:12:10 UTC (rev 3104)
@@ -120,7 +120,9 @@
 	array_multisort($nr, $str);
 	
 	//output javascript vars
-	echo "var arrNodesStr = \"[['root_id', ['Layer','javascript:_foo()'],[".implode("",$str)."]]];\";\n";
+	$arrNodesStr = "[['root_id', ['Layer','javascript:_foo()'],[".implode("",$str)."]]];";
+	$arrNodesStr = str_replace(array("[]", ",]"),array("","]"),$arrNodesStr);
+	echo "var arrNodesStr = \"".$arrNodesStr."\";\n";
 	echo "var categories = {".implode(",", $categories)."};\n";
 }
 else{



More information about the Mapbender_commits mailing list