bookmarklet to find latitude longitude in google maps 19/04/2007
i searched high and low for a simple google maps bookmarklet which would easily output the latitude and longitude of the center of the map. i couldn't find anything that works on the recent version of google maps. so i spent some time inspecting the javascript and here it is:
javascript:alert(window.gApplication.getMap().getCenter())bookmarklet: get center from google maps.
it actually looks suprisingly easy when i finally inspected all the objects in the global scope (window), but it took me ages to figure out how to use the firefox javascript debugger, and then spent ages hitting brick walls be searching through the code for references to where it kept the GMaps2 object. but in fact, it was there all along in the index.html file as gApplication.
- 3 comments
- 2 years, 2 months ago (19/04/2007)

Add a comment
Atom Feed for the Blog Entries