[mapserver-users] setlayersdrawingorder()

Pushkar Pradhan pushkar at ERC.MsState.Edu
Mon Apr 8 14:46:28 PDT 2002


hi,
The above is a function name for map object, there is also
getlayersdrawingorder().
I used getlayers... successfully but when I use setlayers.... I get the
foll. error:
Fatal error: Call to undefined function: setlayersdrawingorder() in
/rstc/user1/erc/pushkar/gis/mcrgdl/view3.php on line 75

Here is my code:
   $layerOrder = array ();
   $layerOrder = $map->getlayersdrawingorder();
   $noOfLayers = count($layerOrder);
   $tmp = $layerOrder[$noOfLayers-1];
   $layerOrder[1] = $tmp;
   $layerOrder[$noOfLayers-1] = 1;
   /* to debug
   foreach($layerOrder as $val) {
      echo "$val ";
   }
   echo " and  ";
   echo is_array($layerOrder);
   */
   $r = $map->setlayersdrawingorder($layerOrder);
These functions were not documented under mapscript I found them in the
mailing list archive
What I am trying to do is change the order of layers being drawn, can
anybody give me the algorithm to do this and the related functions, I am
new to mapscript.
Thanks,

------------------------------------------------------------------------------
PUSHKAR S. PRADHAN
Research Assistant
MISSISSIPPI STATE UNIVERSITY,
STARKVILLE, MS 39759.

Engineering Research Center
Box 9627
Mississippi State, MS 39762-9627
------------------------------------------------------------------------------




More information about the MapServer-users mailing list