[openstreetmap-website] Use a hash anchor for location/zoom persistence (#378)

John Firebaugh notifications at github.com
Tue Jul 30 16:07:50 UTC 2013


I'm in the same camp as @tomhughes -- I hardly ever use the global history UI, and will gladly accept extra entries there in return for the benefits of a persistent hash.

That said, it is unfortunate that some browsers have the behavior they do. There seems to be little consistency between browsers:

Firefox 22: Both location.replace and history.replaceState create new entries in the global history UI.
Chrome 28: Both location.replace and history.replaceState create new entries in the global history UI.
Chrome 30: location.replace updates the existing entry, history.replaceState creates new entries
Opera 12: Neither location.replace nor history.replaceState create new entries (but neither update the existing entry)
Opera 15: Sometimes location.replace creates a new entry, sometimes it updates an existing one (no idea what the criteria are). history.replaceState always creates a new entry.
Safari 6: Both location.replace and history.replaceState create new entries in the global history UI.

The behavior of Firefox is under discussion [here](https://bugzilla.mozilla.org/show_bug.cgi?id=753264).

---
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/378#issuecomment-21802146
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20130730/98c51759/attachment.html>


More information about the rails-dev mailing list