W
W
Way2016-07-15 18:38:49
PHP
Way, 2016-07-15 18:38:49

How to get user's location on google maps and send to mail?

In general, such a question is how to get the location of the user who wrote to us and send it in the form of google maps to the site's mail? (After each conversation (in the pro version), Jivosite sends a letter to the mail and shows where the client wrote from, up to the house number )

Answer the question

In order to leave comments, you need to log in

2 answer(s)
V
Vladimir, 2016-07-16
@YouTy6bl4

To get started
https://developer.mozilla.org/en-US/docs/Web/API/G...
If not supported
https://developers.google.com/maps/documentation/g...
If not enough
https://www.maxmind.com/en/geoip2-precision-services

F
fetis26, 2016-07-15
@fetis26

Well, it takes the user's IP address, makes a request to the service for determining the location by IP and then draws this point on the map. You can also ask the user's browser for geolocation. As far as I remember, Google Maps has methods for determining the user, look in the API.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question