I am trying to work out how to get the feature information onclick for more than one layer, apart from variable etc my code is very simmilar to the openlayers example (http://openlayers.org/en/latest/examples/getfeatureinfo-tile.html)
map.on('singleclick', function(evt) {
document.getElementById('info').innerHTML = '';
var viewResolution = /** @type {number} */ (view.getResolution());
var url = wmsSource.getGetFeatureInfoUrl(
evt.coordinate, viewResolution, 'EPSG:3857',
{'INFO_FORMAT': 'text/html'});
if (url) {
document.getElementById('info').innerHTML =
'<iframe seamless src="' + url + '"></iframe>';
}
});
For example instead of just querying the wmsSource layer/variable I would like to query more than one?