You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It's entirely possible that I'm missing something here, but in IE7 the key:value pairs are not persisting across the entire domain.
They are persisting across page refreshes and browser restarts for individual pages, but as soon as I go to a different page on the same domain, the data is no longer there.
Here's what I'm doing. I'm trying to store a setting across pages. After I load your script, I test if a localStorage value exists already. If it doesn't exist, then I create/set the value:
var settingExists = typeof localStorage.getItem('theKey') === "string";
if ( !settingExists ) {
localStorage.setItem("theKey", "the value");
}
That works great on a page refresh. But when I go to a different page on the same domain, localStorage.getItem('theKey') returns null (where I would expect it to be set already from the previous page).
Am I missing something really basic here?
The text was updated successfully, but these errors were encountered:
I also use this behavior in general, but the approach is useless because IE userData is per folder. This restricts the url structure a lot. My workaround is to have a single Iframe that contains the userData. This way, I have a shared localStorage. The only drawback is that I have to rely on an iframe load event that will usually fire after the main page load event.
It's entirely possible that I'm missing something here, but in IE7 the key:value pairs are not persisting across the entire domain.
They are persisting across page refreshes and browser restarts for individual pages, but as soon as I go to a different page on the same domain, the data is no longer there.
Here's what I'm doing. I'm trying to store a setting across pages. After I load your script, I test if a localStorage value exists already. If it doesn't exist, then I create/set the value:
That works great on a page refresh. But when I go to a different page on the same domain, localStorage.getItem('theKey') returns null (where I would expect it to be set already from the previous page).
Am I missing something really basic here?
The text was updated successfully, but these errors were encountered: