Warning: The Mozilla Developer Network website employs emerging internet requirements that may not be fully supported in some versions of MicroSoft Net Explorer. You'll be able to increase your knowledge of this site by enabling JavaScript.
Introduced in Gecko 1.9.2
(Firefox three.six / Thunderbird three.one / Fennec one.0)
Getting the current place
To get the user's existing site, you'll be able to phone the getCurrentPosition() method. This initiates an asynchronous request to detect the user's place,
Cheap Office Ultimate 2007, and queries the positioning hardware to get up-to-date information. When the place is determined, a specified callback routine is executed. You are able to optionally provide a second callback to be executed if an error occurs. A third, optional,
Office Professional 2010 X86, parameter is an options interface where it is possible to set the maximum age of the request,
Office 2010 Professional Plus Key, and the time to wait for a request.
Use getCurrentPosition() if you want a single placement fix ASAP,
Office 2007 Key Sale, regardless of the accuracy. Devices with a GPS, for example,
Office Professional Plus 2010 Sale, can take a minute or more to get a GPS fix, so less accurate data (IP place or wifi) could be returned to getCurrentPosition() to start.
navigator.geolocation.getCurrentPosition(function( place) do_something(position.coords.latitude, position.coords.longitude););
The above example will cause the do_something() function to execute when the location is obtained.