Florent Clairambault

Google Latitude History

I thought about this service as soon as Google released the Google Latitude service : “It would be great if they could save data so that we could see where we were at a specific time.” And I very quickly published some code to get my position (you could be tracking me right now with it). I thought they would never release the history saving feature as people would have feared for their privacy and things like that.

Access your Google Latitude position from PHP

The code to access your Google Latitude position is even simpler in PHP than it is in .Net : <?PHP header('Content-Type: text/plain'); $userId = '5616045291659744796'; if ( $_GET['user'] ) { if ( is_numeric( $_GET['user'] ) ) $userId = $_GET['user']; else exit('This isn\'t a valid user id.'); } $url = 'http://www.google.com/latitude/apps/badge/api?user='.$userId.'&type=json'; // We get the content $content = file_get_contents( $url ); // We convert the JSON to an object $json = json_decode( $content ); $coord = $json->features[0]->geometry->coordinates; $timeStamp = $json->features[0]->properties->timeStamp; if ( !

Access your Google Latitude position from a .Net app

When I saw that Google Latitude now enables you to access your data by a JSON feed, I decided to make it communicate with a little GPS tracking project of mine. I’m really found of all these ways we now have to make anything communicate with anything. You can build interfaces from any system to any other system really easily. This code enables you to automatically get your GPS position (or the position of a friend) from your JSON Latitude feed.