T
TJ
Hi,
Environment : Asp.net 2.0 / C#
As you know, there is a "Remember me" check box in Login control is VS.NET
2005.
It allows you to get in the page without logging it if user closes browser,
instead of logging out.
It works...however, in the authenticate event, what if session is used?
For example,
In Login.aspx
....Login1_Authenticate....method
{
.....
Session("Test") = "Authentication is done".
e.Authenticated = true;
}
In Default.aspx.
.....Page_Load......
{
...
Response.Write(Session["Test"].ToString());
}
Suppose that user log-in with checked "Remember me" , ...then it displays
"Authentication is done"....
Without explict logging out, user closes the browser, then revist the
default.aspx page..since the user has set the "Remember me", it won't ask the
login page, then load the Default.aspx....According to my testing, the
Session variable was null at this point...
It makes sense because session is lost when browser is closed.....
However...how do I make this working for "Remember me" scenario?
If an user checks the "Remember Me" checkbox, they can close the browser
without logging out, then revisit the page again without logging in
again....In this scenario(Remember me)...I guess I need to keep somehow the
Session...
Should I use something other than in-proc session state??
Any way I can work-around in in-proc session mode for this?
Thanks,
...............................................TJ
Environment : Asp.net 2.0 / C#
As you know, there is a "Remember me" check box in Login control is VS.NET
2005.
It allows you to get in the page without logging it if user closes browser,
instead of logging out.
It works...however, in the authenticate event, what if session is used?
For example,
In Login.aspx
....Login1_Authenticate....method
{
.....
Session("Test") = "Authentication is done".
e.Authenticated = true;
}
In Default.aspx.
.....Page_Load......
{
...
Response.Write(Session["Test"].ToString());
}
Suppose that user log-in with checked "Remember me" , ...then it displays
"Authentication is done"....
Without explict logging out, user closes the browser, then revist the
default.aspx page..since the user has set the "Remember me", it won't ask the
login page, then load the Default.aspx....According to my testing, the
Session variable was null at this point...
It makes sense because session is lost when browser is closed.....
However...how do I make this working for "Remember me" scenario?
If an user checks the "Remember Me" checkbox, they can close the browser
without logging out, then revisit the page again without logging in
again....In this scenario(Remember me)...I guess I need to keep somehow the
Session...
Should I use something other than in-proc session state??
Any way I can work-around in in-proc session mode for this?
Thanks,
...............................................TJ