Suppose I navigated from Page1.html to Page2.html. How do I force Page1.html to Refresh when I navigate back to it from Page2.html using the back button?
I have seen a post saying to include the following code in the document ready method of my page if I’m using jQuery
Hi @liagapi555, the popstate event only gets fired when navigating the same page; instead, you might try reading the state directly (also I’d rather use replaceState() here as pushState() will create a new history entry):
Oh I wasn’t aware of that… sometimes I should actually read the pages I’m linking to, especially the content of red boxes LOL! Anyway I guess in this case we’d have to use the deprecated one as a fallback until further notice (or the other way round?). :-/