sessionStorage on IE 11(Edge) got cleared when user navigate away
Asked Answered
P

1

8

The behaviour of sessionStorage has been documented as it clears when the tab closes. However, in my practice, IE 11(Edge) in my client company clears sessionStorage when user navigates away within the tab (yes, the same tab is still open).

With firefox and chrome, my web app's user can freely navigates away and navigates back, and the data in session storage was kept. But with IE 11(Edge), my user cannot do so.

I checked Microsoft's page on session storage and it reads:

The sessionStorage attribute of the window object maintains key/value pairs for all pages loaded during the lifetime of a single tab (for the duration of the top-level browsing context)

My question is:

Is this a common behaviour of IE's session storage? session storage get cleared if the user navigates away from your domain, whereas other browsers stick to the closure of the browser tab.

Thanks

Postwar answered 15/5, 2018 at 16:23 Comment(4)
The bug is on Internet Explorer 11 or Edge? You are talking about two different versions of the same browser.Ation
Both are the same. IE Edge browser have version 11.xPostwar
did you find any solution for this? @PostwarSpectrochemistry
My use case was that my app will navigate my user to a payment gate, which navigates him/her back. Luckily, this payment gate allows my app to specify the url parameters when my app re-appears in the same tab. Please note: HTTPS is used so my url parameters are encrypted.Postwar
S
1

This might be related to Zone policies in IE/Edge;

https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/13861050/

Session Storage and InPrivate Local Storage is dropped when redirecting across zones. For example, if as a part of your redirection chain you redirect from the intranet to internet, Microsoft Edge will not retrieve the expected session storage data. This issue also exists for local storage in InPrivate mode.

Stationer answered 26/9, 2019 at 14:52 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.