Basic HTML5 Geolocation sample:
Get your location
More advanced Geolocation sample using Google Maps API: