How to use session state?
-
I'm pretty new to use ASP.NET for web page design. I worked out a page in which it got user name and password, etc. When it passed the validation, it goes into the content page, and when the sign out button is pressed, it went back to the sign in page again. Now, if I press the back button from IE after signing out, it can still goes back to the content page. So, how to use the session data to prevent this happened? Many thanks!
-
I'm pretty new to use ASP.NET for web page design. I worked out a page in which it got user name and password, etc. When it passed the validation, it goes into the content page, and when the sign out button is pressed, it went back to the sign in page again. Now, if I press the back button from IE after signing out, it can still goes back to the content page. So, how to use the session data to prevent this happened? Many thanks!
Hi Segal, Call Session.Abandon() in logout button click to destroy session values. Deepak Kumar Vasudevan http://deepak.portland.co.uk/
-
I'm pretty new to use ASP.NET for web page design. I worked out a page in which it got user name and password, etc. When it passed the validation, it goes into the content page, and when the sign out button is pressed, it went back to the sign in page again. Now, if I press the back button from IE after signing out, it can still goes back to the content page. So, how to use the session data to prevent this happened? Many thanks!
If you prevent the browser from caching pages, the user can't retrieve the page via the Back button. Response.Cache.SetCacheability(HttpCacheability.NoCache);
-
If you prevent the browser from caching pages, the user can't retrieve the page via the Back button. Response.Cache.SetCacheability(HttpCacheability.NoCache);