Last active
December 2, 2015 02:31
-
-
Save a-metta/08722d0e61ac562b1682 to your computer and use it in GitHub Desktop.
A collection of snippets from freecodecamp for reference
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This is to access the location from the browser. | |
if (navigator.geolocation) { | |
navigator.geolocation.getCurrentPosition(function(position) { | |
$("#data").html("latitude: " + position.coords.latitude + "<br>longitude: " + position.coords.longitude); | |
}); | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment