[Chameleon-dev] [Bug 1622] LayerAttributes.php does not deal with Mapserver ms prefix

bugzilla-daemon at bugzilla.maptools.org bugzilla-daemon at bugzilla.maptools.org
Wed Dec 20 13:18:24 EST 2006


http://bugzilla.maptools.org/show_bug.cgi?id=1622

bartvde at osgis.nl changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED



------- Additional Comments From bartvde at osgis.nl  2006-12-20 13:18 -------
Fixed in CVS (head and 2.4 branch)

Diff for reference:

cvs diff -u -- LayerAttributes.php (in directory D:\cvs\chameleon24\htdocs\widgets\)
Index: LayerAttributes.php
===================================================================
RCS file: /cvs/maptools/cvsroot/chameleon/htdocs/widgets/LayerAttributes.php,v
retrieving revision 1.15
diff -u -r1.15 LayerAttributes.php
--- LayerAttributes.php	15 Feb 2006 17:08:36 -0000	1.15
+++ LayerAttributes.php	20 Dec 2006 18:11:10 -0000
@@ -825,6 +825,11 @@
     foreach ($tags as $key=>$val)
     {
         // process layer name
+        $pos = strpos($key, ':');
+        if ($pos !== false)
+        {
+          $key = substr($key, $pos+1);
+        }
         if ( strtoupper( $key ) == strtoupper( $szLayer ) )
         {
             $ranges = $val;
@@ -884,6 +889,11 @@
         // only process all non "gml..." values
         if ( strtoupper( substr( $axValues[$i]["tag"], 0, 3 ) ) != "GML" )
         {
+            $pos = strpos($axValues[$i]['tag'], ':');
+            if ($pos !== false)
+            {
+              $axValues[$i]['tag'] = substr($axValues[$i]['tag'], $pos+1);
+            }
             // only add attributes that are in the list
             if ( $bAllowAll || in_array( $axValues[$i]['tag'], $aszAttributes ) )
                 {




------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


Please do NOT reply to this email, use the link above instead to 
login to bugzilla and submit your comment. Any email reply to this
address will be lost.


More information about the Chameleon-dev mailing list