forms authentication & session timeout

  • Thread starter Thread starter Tomk
  • Start date Start date
T

Tomk

I'm using forms authentication in an ASP.NET application. If I am on a page
that requires authentication and my session timesout I am returned to the
login page. Isn't it supposed to take me back to the page where the timeout
happened after I login?
 
Is there a return variable in the querystring called ReturnURL when you are
taken to the login page? IF so, then when the user is authenticated you'll
call the FormsAuthentication.RedirectFromLogin method to create the login
creadentials and return to the URL specified in the querystring.

Hope this helps
Mark Fitzpatrick
Microsoft MVP - FrontPage
 
I have had the same problem
In my case I added some code to the login pag

If (Session.IsNewSession = False) And (Not IsPostBack) The
' display message to user about session timeout
End I

Now when people end up back at the login due to a time out they at least know why

Davi
----- Ted wrote: ----

I have a related issue I think. Once a session has timed out, can that fact be captured somehow so that an error msg can be displayed on the login screen? The first time a user hits the login page there should be no error msg, but if they are redirected to due a timeout, I want to show a message explaining what happened

Perhaps modifying one the http handlers

thanks
 
Back
Top