Getting coordinates for locations from Google Map?

View the page's source code and see if they are being publicly published. For example: http://www.canada411.yellowpages.ca/search/si/1/mcdonalds%20restaurant/Toronto%2C%20ON?showDD=true

If you view the source code on that page, you will be able to find the lat + long of each pushpin marker on the google maps map. Also, each record holds information about its lat + long regardless of it being shown on the map itself. Each webpage will be uniquely formatted. Some poking around in the source code may reveal a lot of information about the data to the user!

Near the bottom of the source:

    pushpinLocals[0] = new Array();
    pushpinLocals[0][0] = 43.732648;
    pushpinLocals[0][1] = -79.404175;
    pushpinLocals[0][2] = "<a href=\"javascript:getListingLink(1)\"  style='font-weight: bold;'>McDonalds Restaurants Inc</a>";
    pushpinLocals[0][3] = "3400 Yonge";
    pushpinLocals[0][4] = "Toronto, ON, M4N2M7";
    pushpinLocals[0][7] = "<br /><b>416-481-8779</b>";
    pushpinLocals[0][8] = customIconSpecification;

Within Google Maps, right-clicking anywhere and then clicking "What's here?" on the contextual menu should return coordinates for the spot you clicked.

Tags:

Google Maps