Click to See Complete Forum and Search --> : How to kill cookie when clicking 'back' on browser


j_sagu
05-13-2003, 08:29 AM
NewUser

On my welcome screen, when a newuser enter their correct creds, they get directed to the changedpassword screen to change their pwd. This message is displayed...

Response.write "Welcome " & sFname & ", as a new user, you are required to change your password..." (this uses cookies that searches whether the user is a neweuser ot not. If new, then the message would be displayed)

ExistingUser

On the welcome screen, if an existing user clicks on the 'changed pwd' link, they also get directed to the changedpassword screen, but alternative this message is displayed...

Response.write "If you are an existing user, please use this screen to change your password..." (this can be for new or existing users)

ok...on the changepwd screen, there is a a link where the user can return back to the welcome screen without entering any creds...this is directed to logout.asp, which kills the cookie, and then directed back to welcome screen.

all good so far, but however, if a new user logs in, cookie is set up, so name is displayed in changepwd screen. If they click 'back' on the browser to go back to the welcome screen, the cookie is still alive. Which means that if you click on the changepwd link on the welcome page, the user would be identified as the newuser...and not as an existing user as cookie is still alive, hence name is displayed.

How do I prevent the user from clicking back? How do I kill the cookie when the user click 'back' on the browser.

Someone told me to use windows (javascript)...I never use javascript before...

Help appreciated, quite urgent. Thanks! ;)