Preserve state of URL (HTML5 localstorage)