X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/6c66507427961a22a8f282b5b2f4ab7fda1dad6f..207f257d1280485582e401bf5c8acdb41b212b97:/app/views/site/index.rhtml diff --git a/app/views/site/index.rhtml b/app/views/site/index.rhtml index b8fcf579e..37004e25b 100644 --- a/app/views/site/index.rhtml +++ b/app/views/site/index.rhtml @@ -10,14 +10,14 @@
- +
@@ -27,7 +27,7 @@ http://openstreetmap.org/ - Licensed under the Creative Commons Attribution-Share Alike 2.0 license by the OpenStreetMap project and its contributors. + <%= t 'site.index.license' %>
@@ -170,10 +170,12 @@ end var zoom = map.getZoom(); var layers = getMapLayers(); var extents = getMapExtent(); + var expiry = new Date(); 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; + + expiry.setYear(expiry.getFullYear() + 10); + document.cookie = "_osm_location=" + lonlat.lon + "|" + lonlat.lat + "|" + zoom + "|" + layers + "; expires=" + expiry.toGMTString(); } function resizeContent() {