Closed vmulot closed 4 years ago
Not quite sure if I understand you correctly but the Storelocator itself can tell you the distance to the store from the given location
If you'd want to use the browsers location you might add you script to the mod_storelocator_search.html5
and populate all the hiddens fields (which also contain the coordinates) and submit this form automatically.
That way the user will end up in the results list having all distances shown ;)
Thanks for answering ! i tried your tip but how do you handle the submit only the first time and only if coords are available ? i tried to check the GET params (lat and lng) but it keep submitting form.
As github is messing up my code, here is a gist of what i did
Thanks again for your help !
Hi, it's not a bug, but i'd like to get User Position (with the browser prompt for geolocation), center Map on it, and get the distance calc for stores around him. i didn't find if your module can handle that. i' tried myself, i managed to get user position, centering the map, but i don't have the distance in the store list.
any advice/idea/update? :)
thanks