tenderlove (owner)

Revisions

gist: 219787 Download_button fork
public
Public Clone URL: git://gist.github.com/219787.git
Embed All Files: show embed
test.html #
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <script>
      navigator.geolocation.getCurrentPosition(function(pos) {
        var lat = pos.coords.latitude;
        var lon = pos.coords.longitude;
        alert("lat: " + lat + " lon: " + lon);
      }, null);
    </script>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
</head>
  <body>
  </body>
</html>