};
OpenLayers._getScriptLocation = function () {
- // Should really have this file as an erb, so that this can return
+ // Should really have this file as an erb, so that this can return
// the real rails root
return "/openlayers/";
}
function addObjectToMap(url, zoom, callback) {
var layer = new OpenLayers.Layer.GML("Objects", url, {
format: OpenLayers.Format.OSM,
+ style: {
+ strokeColor: "blue",
+ strokeWidth: 3,
+ strokeOpacity: 0.5,
+ fillOpacity: 0.2,
+ fillColor: "lightblue",
+ pointRadius: 6
+ },
projection: new OpenLayers.Projection("EPSG:4326"),
displayInLayerSwitcher: false
});
callback(extent);
}
});
-
+
map.addLayer(layer);
layer.loadGML();
strokeColor: '#ee9900',
fillOpacity: 0
});
-
+
vectors.addFeatures(box);
return box;