How to prevent going back to the previous page by hitting the Back button ?
843842Oct 22 2008 — edited Oct 23 2008In the html code I generate from my servlet, I have the following :
<Html>
<Head>
<Title>Cox Part Time Benefit App Login Page</Title>
<Meta http-equiv="Pragma" content="no-cache">
<!-- Pragma content set to no-cache tells the browser not to cache the page. This may or may not work in IE -->
<Meta http-equiv="expires" content="0">
<!-- Setting the page to expire at 0 means the page is immediately expired. Any vales less then one will
set the page to expire some time in past and not be cached. This may not work with Navigator -->
<Meta http-equiv="Cache-Control" content="no-cache">
<!-- This directive indicates cached information should not be used and instead requests should be forwarded
to the origin server. This directive has the same semantics as the PRAGMA:NO-CACHE -->
</Head>
......
I hope it can prevent user from going back to the previous page by hitting the Back button on the browser, but it doesn't, what's the right way to do it ?
Frank