Skip to content
Advertisement

Fetch latitude and longitude from google map

I have an embedded Google map in my website which has a ‘Place Autocomplete widget’ which we use to get a place ID, name etc. when searching.

I also need to get the latitude and longitude of a marked place.

JavaScript

Advertisement

Answer

You can retrieve the lat/lng from the geometry property in the Place model you retrieve:

JavaScript
User contributions licensed under: CC BY-SA
4 People found this is helpful
Advertisement