I don\'t have any previous javascript experience.
I\'m trying to implement the following function which I wish to use to return the values lat and lng:
f
Use a callback to handle the geocoding results:
function myCallback(lat, lng) {
// Process lat and lng.
}
function get_address(callback) {
var geocoder = new google.maps.Geocoder()
geocoder.geocode({ address: "SE-17270 Sverige"},
function(locResult) {
var lat = locResult[0].geometry.location.lat();
var lng = locResult[0].geometry.location.lng();
callback(lat, lng);
}
);
}
....
get_address(myCallback);