Search code examples
geo

How to write script for posting your geo location to a website?


You see it everywhere these days...

Facebook will display your geo location along with your status update. "John Doe says this...near Austin, Tx"

In Google maps you can click the "round dot" and it will show you where you are geographically and allow you to create your direction around that.

What's the coding behind it? I'd like to start implementing this into a few things (more so how facebook does it). Does anyone have an idea? I'm guessing a combo between php, javascript, Database (ajax) and perhaps a "GEO api" of some sorts... Along with w/ some good ol' fashion html/css.

Am I on the right thinking path here?


Solution

  • It's the Geolocation API . Have a look here: http://html5doctor.com/finding-your-position-with-geolocation/