Inside your getfeatureinfo request, use a conditional statement testing for
features before the popup is called, such as:

 

                if(event.features.length > 0){

                ..

..

}

 

Hope this helps,

 

Jerome

 

 

From: openlayers-users-boun...@lists.osgeo.org
[mailto:openlayers-users-boun...@lists.osgeo.org] On Behalf Of Raffaele
Morelli
Sent: Friday, May 10, 2013 8:31 AM
To: openlayers-users@lists.osgeo.org
Subject: [OpenLayers-Users] WFSGetFeatureInfo and
OpenLayers.Popup.FramedCloud

 

Hi,

 

I am juggling with WFS and info popup in
http://openlayers.org/dev/examples/getfeatureinfo-popup.html

 

Everything works fine but the info popup always raises, even when clicking
outside the layers.

How can I prevent this behaviour? (if possible)

 

regards

/r

_______________________________________________
Users mailing list
us...@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/openlayers-users

Reply via email to