[Users] WMSGetFeatureInfo() issue
Kris Nackaerts
knackaerts at gmx.net
Mon Mar 22 10:04:27 CET 2010
Hi All,
First, I'm new to geoExt, apologies when this is a trivial issue.
The following code is not working correctly. When using firebug, the request that is send to Geoserver is correct, and geoserver returns the expected data. e.text however remains empty. Note the datalayer queried is a 16 bit raster dataset.
var featureInfo = new OpenLayers.Control.WMSGetFeatureInfo();
featureInfo.events.on({
getfeatureinfo: function(e) {
alert(e.text);
}
});
map.addControl(featureInfo);
featureInfo.layers = [bathy];
featureInfo.activate();
The issue: e.text remains empty.
Some additional info:
* e.request.statusText='OK'
* e.request.status=0
* e.request.readyState=4
* e.request.responseText=""
Based on Firebug, I can discover that Geoserver returns the following (by manually copying/pasting the URL request into a new page):
<html>
<head>
<title>Geoserver GetFeatureInfo output</title>
</head>
<style type="text/css"> ... </style>
<body>
<table class="featureInfo">
<caption class="featureInfo">DMT:dmt_original_values_proto</caption>
<tr>
<th>fid</th>
<th >GRAY_INDEX</th>
</tr>
<tr>
<td></td>
<td>1558.0</td>
</tr>
</table>
<br/>
</body>
</html>
Any ideas, comments ware welcome,
Kris
--
Sicherer, schneller und einfacher. Die aktuellen Internet-Browser -
jetzt kostenlos herunterladen! http://portal.gmx.net/de/go/chbrowser
More information about the Users
mailing list