📜 ⬆️ ⬇️

Advanced use of Google Latitude

Where I am? Or how to completely destroy privacy and show everyone where to look for me!

All who used the google maps version for mobile phones probably already know about the great feature - Google Latitude . Having a gps receiver and activating it in a mobile application you get the opportunity to transfer your current location to your friends, as well as, in turn, to see their coordinates.

Great idea, but I want more!

First of all, I want to have api.
Secondly - I want to get the current GPS coordinates and record them in the track.
And most importantly - I want to show my position and track on the map on my blog.
')
How to do it?

So far, api to latitude is not, but there was a wonderful blog for Google Plots Public Location Badge

Hurray, this solves all my problems!
So
1 - Put a google map on a mobile device (for example, by going to it from m.google.com )
2 - Activates Google Latitude there (you must have a google account or email at gmail.com!)
3 - Go to Google Location Badge and activate it.
4 - After receiving the code for the blog, look at it userid
5 - And voila - at
www.google.com/latitude/apps/badge/api?user=WASHID&type=kml
or
www.google.com/latitude/apps/badge/api?user=WASHid&type=json
We get our coordinates either in KML or in JSON format!

6 - Next is a matter of technology - write a script periodically querying the coordinates and writing them into the database
result can be seen
right here

An important point!
Knowing USERID, you can get user coordinates ignoring all access demarcations in latitude. This is said on the page, but it is still strange that google suggests inserting it into an iframe! My version of this lack has no, userid is hidden in a script running on the server.


Interesting moment!
It works even without a GPS receiver! Coordinates are roughly determined by the nearest base stations.

sources of
http://www.google.com/latitude/apps/badge
http://www.google.com/support/mobile/bin/answer.py?answer=144216
http://radar.oreilly.com/2009/05/googles-sneaky-launch-of-latitudes-location-sharing-api.html

UPD
Habraeffekt did the trick, mytrails.ru had to patch right on the go, and besides, a very unpleasant problem was discovered in cheap Dlinke through which the server is connected to the Internet. A number of problems were connected with this site, site, write in a personal, I will correct.

Source: https://habr.com/ru/post/69172/


All Articles