Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Can i save the features on selecting points into same json file?
- draw.on('drawend',
- function(evt) {
- console.log(evt.feature);
- var parser = new ol.format.GeoJSON();
- var features = floodAlertLayer.getSource().getFeatures();
- var featuresGeoJSON = parser.writeFeatures(features);
- var text = JSON.stringify(featuresGeoJSON);
- // document.getElementById('info').innerHTML = text;
- // alert(features.get("COUNTY"));
- $.ajax({
- url: 'FloodAlert.json',
- type: 'POST',
- data: text
- }).then(function(response) {
- console.log(response);
- });
- },
- this);
- }`
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement