1. Simplest, our Hello World, displays visitors location in a box.
The following JavaScript fills in parts of the HTML with the values returned by our Geo functions:
<script type="text/javascript">
document.getElementById("lat").innerHTML = getLat();
document.getElementById("lng").innerHTML = getLng();
</script>
2. A map example, which gets visitors
location information, then centers a Google map around it.
In this example we are using the visitor's (yours) latitude and longitude
to center the Google map, with:
<script type="text/javascript">
var map = new GMap2(document.getElementById("map"));
map.setCenter(new GLatLng(getLat(), getLng()), 12);
</script>
3. A more involved sample which
gets visitors location information, then queries to get auto body shops
in that area, and finally displays them on a Google map.