[OpenLayers-Users] Assign layers dinamically to WMSGetFeatureInfo control

Micho Garcia michogar at gmail.com
Tue Aug 14 03:41:13 PDT 2012


Works perfect!!,

my problem was with my code, I had an error because I used
getControlsByClass to select the WMSGetFeatureInfo control and this method
returns an array of controls not a control. As you can see, a stupid
mistake!!

Apologize for the inconveniences.

Micho García
GIS Developer Artisan
michogarcia.org
geomati.co


2012/8/13 Phil Scadden <p.scadden at gns.cri.nz>

>
> > I'm working with WMSGetFeatureControl and I need to change dynamically
> > the layers that I go to get info. I've tried assigning a layers array
> > to WMSGetFeatureControl layers property, but this fails.
> If I had to guess, I would say you are doing
>
> myWMSGFScontrol.layers = myLayer;
>
> instead of
>
> myWMSGFScontrol.layers = [myLayer];
>
> ???
>
>
>
> Notice: This email and any attachments are confidential. If received in
> error please destroy and immediately notify us. Do not copy or disclose the
> contents.
>
> _______________________________________________
> Users mailing list
> Users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/openlayers-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/openlayers-users/attachments/20120814/9d90f839/attachment.html>


More information about the Users mailing list