0

Maybe someone could help me how to use plugin Leaflet Control Search with WFS from GeoServer. The control is added to the map. But when I try to search a single feature with this plugin, the WFS response with full list of all features. How should I use the Leaflet Control Search to get ony one, searched feature from WFS. I'm quite new in Leaflet and GeoServer. Please, help. Here is what I made:

mapid.addControl(new L.Control.Search({
   url: "http://localhost:8000/geoserver/przejazdy/ows?service=WFS&version=1.0.0&request=GetFeature&typeName=przejazdy:lokalizacje&outputFormat=application/json"
   propertyLoc: ['wsp_lat', 'wsp_lon'],
   propertyName: 'nr_id',
   zoom: 16,
   markerLocation: true
}));    
  • Welcome to gis.SE! Code is missing from your question. Please edit your question and add the code. – Stefan Jan 28 at 14:57

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.