setMapExtent(bbox);
<% if box %>
- box = addBoxToMap(bbox);
+ // IE requires Vector layers be initialised on page load, and not under deferred script conditions
+ Event.observe(window, 'load', function() {addBoxToMap(bbox)});
<% end %>
<% else %>
var centre = new OpenLayers.LonLat(<%= lon %>, <%= lat %>);
var layers = getMapLayers();
var extents = getMapExtent();
- updatelinks(lonlat.lon, lonlat.lat, zoom, layers, extents);
-
+ updatelinks(lonlat.lon, lonlat.lat, zoom, layers, extents.left, extents.bottom, extents.right, extents.top);
+
document.cookie = "_osm_location=" + lonlat.lon + "|" + lonlat.lat + "|" + zoom + "|" + layers;
}