[Chameleon] layer manager
pspencer at dmsolutions.ca
Fri Oct 15 14:29:14 EDT 2004
There are two ways. First, there is a form variable that is set when
you select a layer in this way, SELECTED_LAYERS. Second, there is
metadata set on each layer when the page is submitted which you can test
if( $oLayer->getMetadata( "selected" ) == "1")
//layer is selected.
Note that this is updated during ParseURL processing so it may not be
available to your widget in ParseURL unless you set a lower priority
that the SelectLayers widget or you access it in DrawPublish (or one of
the GetXXXX functions)
Naijun Zhou wrote:
> I'm adding the layer management buttons (up/down/delete) into the main
> viewer page instead of launching a new window. When a layer is selected
> from the radio button in the main page, I hope to catch the selected
> layer's name in another widget. But I cannot do this.
> I think the radio button is defined in lengend_template.html:
> <td><input type="radio" name="my_legend"
> onclick="CWCSelectLayer('[leg_layer_name]', true)"[if name=selected
> value=1] CHECKED[/if] ></td>
> <td><a href="#"
> How can I get the selected layer name in another php widget? Are there
> hidden variables I missed?
> Thank you very much!
> N. Zhou
> Express yourself instantly with MSN Messenger! Download today - it's
> FREE! http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
> Chameleon mailing list
> Chameleon at lists.maptools.org
More information about the Chameleon