I was wondering how to set the position of the map if there is no available geolocation or if it is disabled in the browser.
Find an example here : http://jquery-ui-map.googlecode.com/svn/trunk/demos/jquery-google-maps-geolocation.html/
$('#map_canvas').gmap({ 'disableDefaultUI':true, 'callback': function() {
var self = this;
self.getCurrentPosition(function(position, status) {
if ( status === 'OK' ) {
self.set('clientPosition', new google.maps.LatLng(position.coords.latitude, position.coords.longitude));
self.addMarker({'position': self.get('clientPosition'), 'bounds': true});
self.addShape('Circle', { 'strokeWeight': 0, 'fillColor': "#008595", 'fillOpacity': 0.25, 'center': self.get('clientPosition'), 'radius': 15, clickable: false }); self.option('zoom' ,8);
}
});
}});
}).load();
});
</script>