I can get my current location (using this Google Maps API sample). I would like to output the resulting coordinates to HTML (in a similar way to This JSFiddle).
I believe the JSFiddle uses this code to extract the coordinates, though I am not interested in the 'dragging' functionality:
google.maps.event.addListener(marker, 'dragend', function (event)
{
document.getElementById("lat").value = event.latLng.lat();
document.getElementById("long").value = event.latLng.lng();
});
Any help would be great!