Hello!!
As the title says... I trying to access that data associated with a vector layer but not having any success.
I get the following error:
"No QUERY_LAYERS has been requested, or no queriable layer in the request anyways "
I am using geoserver, openlayers and and the script shown below....
map.events.register('click', map, function (e) {
document.getElementById('nodelist').innerHTML = "Loading... please wait...";
var params = {
REQUEST: "GetFeatureInfo",
EXCEPTIONS: "application/vnd.ogc.se_xml",
BBOX: map.getExtent().toBBOX(),
X: e.xy.x,
Y: e.xy.y,
INFO_FORMAT: 'text/html',
QUERY_LAYERS: map.layers[1].options.typename,
FEATURE_COUNT: 50,
Layers: 'monitor:Routers',
Styles: '',
Srs: 'EPSG:4326',
WIDTH: map.size.w,
HEIGHT: map.size.h,
};
OpenLayers.loadURL("http://tobagoborn.com:8080/geoserver/wfs", params, this, setHTML, setHTML);
OpenLayers.Event.stop(e);
});
Any suggestion as to what I am doing wrong would be very much appreciated
Regards Chris