Integrate Autocomplete Functionality in Leaflet/OpenStreetMap with WordPress

geocodingleafletopenstreetmapqgis-pluginswordpress

I am trying to add the autocomplete functionality similar to what you have here https://community.algolia.com/places/examples.html#advanced to the search form in my website. Unfortunately there are no pre-existing plugins for Leaflet https://leafletjs.com/ & OpenStreetMap maps integrations like you have for Google Places autocomplete for WordPress templates.

Is there an easy way of integrating in existing template searchforms like you have in the examples here?

Looking for some suggestions.

The page I need to change: http://demo.ohmyproperty.com/

Best Answer

I used both the location provider and Autocomplete API provided by https://github.com/location-iq/leaflet-geocoder. This autocomplete feature utilises a Search API that returns place predictions in response to an HTTP request. The request specifies a textual search string and optional geographic bounds and works as expected.

Related Question