[OpenLayers-Users] WMSGetFeatureInfo: find out layer names

Frank Broniewski brfr at metrico.lu
Tue Jan 5 05:22:19 EST 2010


Hello list,

I am using the WMSGetFeatureInfo function for querying my WMS layers. Works 
like a charm.
In my map I have the possibility to query more than one layer for 
information. And now I search for a solution to find out for what layer the 
response was returned. Looking at the returned result from Firebug I can see 
that the common structure for the response is <msGMLOutput> and the next 
node child contains the layer name with the extension _layer. How can I 
access this node?

Right now I use the following approach to work with the reponse:
	var reader = new OpenLayers.Format.WMSGetFeatureInfo();
	var features = reader.read(response.text);

Does the read_msGMLOutput give me more options to work with the returned 
XML? Or do I need to convert the response to an OpenLayers.Format.XML first?

Many thanks

Frank



Frank Broniewski

Metrico s.àr.l. ( http://www.metrico.lu )
36, rue des Romains
L-5433 Niederdonven
Luxembourg

Fon: +352 26 74 94 28
Fax: +352 26 74 94 99 




More information about the Users mailing list