I guess you just need a new LayerObj, as described in the mapscript documentation (http://mapserver.gis.umn.edu/docs/reference/phpmapscript-class) :
Layer Objects can be returned by the MapObj class, or can be created
   using:

   layerObj ms_newLayerObj(MapObj map [, layerObj layer])

   A second optional argument can be given to ms_newLayerObj() to create
   the new layer as a copy of an existing layer. If a layer is given as
   argument then all members of a this layer will be copied in the new
   layer created.


You can then play with :
boolean moveLayerUp(int layerindex)
        Move layer up in the hierarcy of drawing.

   boolean moveLayerDown(int layerindex)
        Move layer down in the hierarcy of drawing.

   array   getlayersdrawingorder()
        Return an array containing layer's index in the order which they
        are drawn.

   boolean  setlayersdrawingorder(array layeryindex)
        Set the layer's order array. The argument passed must be a valid
        array with all the layer's index.
        Return TRUE on success or else FALSE.


to set your layer's correct place into the map.

Hope that helps,


Guillaume

Hans Castorp a écrit :
Hi to all,

If map->insertLayer() isn't available in php mapscript, how can I insert a runtime created layer using php mapscript???

Thanks in advance.

Hans Castorp.


------------------------------------------------------------------------

Enviado desde Correo Yahoo! <http://us.rd.yahoo.com/mailuk/taglines/isp/control/*http://us.rd.yahoo.com/evt=52431/*http://es.docs.yahoo.com/mail/overview/index.html>
La bandeja de entrada más inteligente.


------------------------------------------------------------------------

_______________________________________________
mapserver-users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/mapserver-users


_______________________________________________
mapserver-users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Reply via email to