Force a page refresh when page visited from back button

Mark_54 picture Mark_54 · Feb 9, 2012 · Viewed 16.3k times · Source

How can I force a page refresh of page 1 when a user returns to it from page 2 by pressing the back button? Are there vbscript or javascript approaches or is it down to set the 'no cache' somehow?

Answer

Set a cookie on page 2.

If the cookie is detected on page 1, reload the page.