M
Mufasa
In my website, we are using forms authentication. But every once in a while,
it will seem to log you out suddenly when your in the middle of doing
something.
In my login page, I do the following code once the person has logged in
successfully:
FormsAuthentication.Initialize()
'The AddMinutes determines how long the user will be logged
in after leaving
' the site if he doesn't log off.
Dim fat As FormsAuthenticationTicket = New
FormsAuthenticationTicket(1, tbUserID.Text, DateTime.Now, _
DateTime.Now.AddMinutes(30), True, lsRole,
FormsAuthentication.FormsCookiePath)
Response.Cookies.Add(New
HttpCookie(FormsAuthentication.FormsCookieName, _
FormsAuthentication.Encrypt(fat)))
Is there anything else I need to do or will this take care of it.
TIA - Jeff.
it will seem to log you out suddenly when your in the middle of doing
something.
In my login page, I do the following code once the person has logged in
successfully:
FormsAuthentication.Initialize()
'The AddMinutes determines how long the user will be logged
in after leaving
' the site if he doesn't log off.
Dim fat As FormsAuthenticationTicket = New
FormsAuthenticationTicket(1, tbUserID.Text, DateTime.Now, _
DateTime.Now.AddMinutes(30), True, lsRole,
FormsAuthentication.FormsCookiePath)
Response.Cookies.Add(New
HttpCookie(FormsAuthentication.FormsCookieName, _
FormsAuthentication.Encrypt(fat)))
Is there anything else I need to do or will this take care of it.
TIA - Jeff.