Prepare for your Next Interview
This is a discussion on Why logout does not work in ASP.NET within the ASP.NET forums, part of the Web Development category; Manually session check to enter in a web page in asp.net. It works fine.When logout, works fine. But, after logout , when press browser back button it back to ...
|
|||
|
Why logout does not work in ASP.NET
Manually session check to enter in a web page in asp.net. It works fine.When logout, works fine. But, after logout , when press browser back button it back to the previous page, session check not work.Why?
code for page_load() with session check: protected void page_load() { if(session["id"]==null) { server.Transfer("../Index.aspx"); else { // .... } } } code for logout button: { session["id"]=null; server.Transfer("../Index.aspx"); } |
| Sponsored Links |
|
|||
|
Re: Why logout does not work in ASP.NET
you have to use javascript for disable back button.
<head runat="server"> <script language="javascript"> history.forward(); </script> Last edited by aditi.ptl : 03-14-2008 at 11:33 AM. |
![]() |
|
| Thread Tools | |
| Display Modes | |
|
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How the joins work in SQL | savitha_shankar | Database General | 11 | 07-15-2008 11:06 AM |
| Work for an MNC | Geek_Guest | Career Advice | 1 | 09-03-2007 06:36 AM |
| Applet doesn't work in IE 7.0 | psuresh1982 | Java | 3 | 07-20-2007 11:39 AM |
| I don't have any experience to work. | BMP1980 | Career Advice | 2 | 03-13-2007 11:04 AM |
| Whether in Team work | blenda | Interviews | 1 | 08-29-2006 05:31 AM |