Make sure vector-wfs example works in JSFiddle

This commit is contained in:
Bart van den Eijnden
2015-05-19 21:08:30 +02:00
parent 1ac41c7403
commit 1dbf8cd4d6

View File

@@ -28,9 +28,12 @@ var vectorSource = new ol.source.Vector({
}))
});
// the global function whose name is specified in the URL of JSONP WFS
// GetFeature requests
var loadFeatures = function(response) {
/**
* JSONP WFS callback function.
* @param {Object} response The response object.
*/
window.loadFeatures = function(response) {
vectorSource.addFeatures(geojsonFormat.readFeatures(response));
};