18.11.2017 Views

html5_tutorial

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

HTML5<br />

maximumAge<br />

Number<br />

Specifies the expiry time in milliseconds for cached<br />

location information.<br />

Example<br />

Following is a sample code which shows how to use above mentioned methods:<br />

function getLocation() {<br />

var geolocation = navigator.geolocation;<br />

geolocation.getCurrentPosition(showLocation, errorHandler,<br />

{maximumAge: 75000});<br />

}<br />

134

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!