I've got this working because if I click any other layers the bubble pops up
with nothing but if I click my parks layer the proper information is shown.
My problem is can I get the bubble to not pop up at all if the parks layer
isn't clicked? I am just trying to make a "hotspot" type scenario where each
individual layer will show only properties of that layer clicked which is
why I made this one for the parks layer and plan on making one for each
layer I want to display information on, or is there a better way?
var hotspot_info = new OpenLayers.Control.WMSGetFeatureInfo({
url: 'http://ITS701X5J1/RedWMS/Request.aspx',
title: 'Identify features by clicking',
queryVisible: false,
layers: [layer_Major_Parks],
eventListeners: {
getfeatureinfo: function(event) {
map.addPopup(new OpenLayers.Popup.FramedCloud(
"featurePopup",
map.getLonLatFromPixel(event.xy),
null,
event.text,
null,
true
));
}
}
});
map.addControl(hotspot_info);
hotspot_info.activate();
--
View this message in context:
http://osgeo-org.1803224.n2.nabble.com/Modifying-WMSGetFeatureInfo-to-return-only-info-from-1-layer-tp5531392p5531392.html
Sent from the OpenLayers Users mailing list archive at Nabble.com.
_______________________________________________
Users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-users