At my old job we rolled out our own drill down query tool that fired whenever somebody right-clicked on the map.
It just passed the coordinates of the click along with the visible layers via AJAX to a server side script that queried our database. In our case our database drove both the application and the wms service and we had easy access (full control) across all of our services. The returned information (json) was then displayed in a table within a framed cloud. It worked for the client and made for some fun experimentation in openlayers. Wally On Wed, Jan 26, 2011 at 4:10 PM, elshae <[email protected]> wrote: > > Hello OpenLayers Users, > > I have seen the following thread which describes my case to a T. > > http://osgeo-org.1803224.n2.nabble.com/OL-2-9-1-Restrict-WMSGetFeatureInfo-according-the-layers-td5460019.html > > However, this thread is a little old. Is it true that there is no possible > solution or workaround for this situation to date? It is really confusing > for users to get feature info for layers which are not appearing on the map > at the time of the request. > > To recap the issue: > I have layers that I set the minScale so that they are not visible at all > zoom levels. Even though these layers are not visible at these levels, > feature info is returned... > > An example of such a layer: > var villages = new OpenLayers.Layer.WMS( > "Villages", " > http://localhost:8080/geoserver/gwc/service/wms", > {layers: 'cite:villages', transparent: true}, {layerId: 'Villages', > isBaseLayer: false, displayInLayerSwitcher: true, visibility: false, > minScale: 1733376.0653286723} > ); > > //Opening featureInfo code > var info = new OpenLayers.Control.WMSGetFeatureInfo({ > url: 'http://localhost:8080/geoserver/wms', > layerUrls: > ["http://localhost:8080/geoserver/gwc/service/wms"], > title: 'Identify features by clicking', > layers: [villages], > queryVisible: true, > eventListeners: { > getfeatureinfo: function(event){ > > Any ideas/hints/solutions would be so greatly appreciated! > > Thanks, > > elshae > -- > View this message in context: > http://osgeo-org.1803224.n2.nabble.com/Disable-WMSGetFeatureInfo-for-layers-which-are-currently-not-visible-tp5964206p5964206.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 >
_______________________________________________ Users mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/openlayers-users
