};
OpenLayers._getScriptLocation = function () {
+ // Should really have this file as an erb, so that this can return
+ // the real rails root
return "/openlayers/";
}
}
function setMapCenter(center, zoom) {
+ zoom = parseInt(zoom);
var numzoom = map.getNumZoomLevels();
if (zoom >= numzoom) zoom = numzoom - 1;
map.setCenter(center.clone().transform(epsg4326, map.getProjectionObject()), zoom);