X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/d69a518b9e69107503b332728dfa583594293ea1..abb66fa808f09469306e6b03b21539eb57b74d38:/app/views/site/index.rhtml diff --git a/app/views/site/index.rhtml b/app/views/site/index.rhtml index 482ed85b8..2cca4d529 100644 --- a/app/views/site/index.rhtml +++ b/app/views/site/index.rhtml @@ -94,9 +94,11 @@ by the OpenStreetMap project and its contributors. function mapInit(){ map = createMap("map"); + <% unless OSM_STATUS == :api_offline or OSM_STATUS == :database_offline %> map.dataLayer = new OpenLayers.Layer("Data", { "visibility": false }); map.dataLayer.events.register("visibilitychanged", map.dataLayer, toggleData); map.addLayer(map.dataLayer); + <% end %> <% if bbox %> var bbox = new OpenLayers.Bounds(<%= minlon %>, <%= minlat %>, <%= maxlon %>, <%= maxlat %>);