[Chameleon] Change layer status

Alexys Herleym Rodriguez Avellaneda alexys_6 at yahoo.es
Thu Feb 14 14:20:53 EST 2008

Hi Friends,

I have the next case.

I use this code for a current layer in the map:

$oMap = $this->moMapObject->oMap;
$oLayer = $oMap->getLayerByName("Municipios");
if ($oLayer->status == MS_OFF || $oLayer->status == MS_DEFAULT)
           {$oLayer->set("status", MS_ON);}

But the layer Municipios still is off (th layer doen't show). 

By other side i do a copy of the layer Municipios y that work fine, i mean the new layer apper and is on:

$oHighlight = ms_newLayerObj($oMap, $oLayer); 
$oHighlight->set("name", $oLayer->"Municipios_copy");
$oHighlight->set("status", MS_ON);

I need to send another command to refresh in the case the layer already exist?


Alexys H

¿Con Mascota por primera vez? Sé un mejor Amigo. Entra en Yahoo! Respuestas http://es.answers.yahoo.com/info/welcome
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.maptools.org/pipermail/chameleon/attachments/20080214/0927fe8d/attachment.html

More information about the Chameleon mailing list