onepieceking
Well-known member
- Joined
- Sep 20, 2006
- Messages
- 64
- Programming Experience
- 1-3
Hi,
I have 3 web forms, namely login.aspx, main.aspx and logoff.aspx. I have put "Response.Cache.SetCacheability(HttpCacheability.NoCache)" in Page_Load of login.aspx and main.aspx.
When the user login from login.aspx, a session is set [Session("User")=true]. In main.aspx, it will check if Session("User") is true. If it is false or nothing, it will redirect to login.aspx.
the logoff.aspx will call Session.Abandon() when the user click logoff in main.aspx.
The problem now is that:
1) User login in login.aspx
2) Once in main.aspx, User will click "logoff".
3) User is directed to login.aspx
4) When User click "Back" button on IE, main.aspx is SHOWN!! By right, with NoCache and the checking of Session("User"), login.aspx should be shown when User click on "Back"
Please advise. thanks
I have 3 web forms, namely login.aspx, main.aspx and logoff.aspx. I have put "Response.Cache.SetCacheability(HttpCacheability.NoCache)" in Page_Load of login.aspx and main.aspx.
When the user login from login.aspx, a session is set [Session("User")=true]. In main.aspx, it will check if Session("User") is true. If it is false or nothing, it will redirect to login.aspx.
the logoff.aspx will call Session.Abandon() when the user click logoff in main.aspx.
The problem now is that:
1) User login in login.aspx
2) Once in main.aspx, User will click "logoff".
3) User is directed to login.aspx
4) When User click "Back" button on IE, main.aspx is SHOWN!! By right, with NoCache and the checking of Session("User"), login.aspx should be shown when User click on "Back"
Please advise. thanks