I have a very simple use-case: Page1 is a list. When clicking on a list item, user goes to Page2 where she can make changes to that item. When navigating back, Page1 should reflect the changes.
Note: Page1 and Page2 are different pages for the server (this website is not a single-page webapp).
Disabling cache doesn't seem to solve the issue. Setting the Cache-Control
header to no-cache, no-store
works in Firefox (page refreshed upon navigating back), but fails in IE 11, Chrome desktop, Opera desktop, Safari OS X and Safari iOS. Surprisingly, it works on Chrome Android on my device.
I doubt there is a way to have the page refreshed that way on all those browsers, but I'll ask just in case: Is it possible to have a page consistently reloaded on all major browsers when navigating back?
If the answer is no, then Javascript may come to the rescue? For example some event(s) that I can listen to, and which will be triggered when navigating back, something that would work on all major browsers.
Basically, any solution where I can have updated data in Page1 when navigating back.
Thanks for any help!
Edit: I tested the "unload" trick explained at Is there a cross-browser onload event when clicking the back button?, and it doesn't work in Safari on Mac (V7.0.4).