Finding a visitor's geo location: the google.loader

Programming for Search Engines 101. An area for avid PHP and .NET developers to chat about Programming techniques and how to make better use of search engines.

Moderator: Moderators

Finding a visitor's geo location: the google.loader

Postby Mike » Fri Sep 04, 2009 8:51 am

Stumbled upon the google.loader object recently - lots of useful information that google pulls in for you without even having to ask. Specifically, I was trying to ascertain which city a visitor was coming from and display contact specific to that city.

Enter the google.loader.ClientLocation object.

No need for code snippets here of course, Google does a pretty good job already of documenting their codebase.



If you want to display geo-specific content, this is a good start. While it's client-side (so you'll have to be crafty in how you sanitize and implement it) and so not quite as robust as a server-side solution, hey, it's free and it works great for basic geoip functionality.

Mike
Mike
 

Return to Programming

Who is online

Users browsing this forum: No registered users and 9 guests