the following code create a Forms authentication Cookie, and Set authentication cookie, then redirect to originally requested URL, if requested URL does not exist, it would redirect to default.aspx by default. username: Name of the user for cookie authentication purposes. the second parm createPersistentCookie determines whether the authentication cookie is persisitent, if it is false, cookie would be expired upon closing of the browser.
FormsAuthentication.RedirectFromLoginPage (UserName.Text, false); |
the statement above is equivalent to the following :
![None.gif](/Images/OutliningIndicators/None.gif)
![None.gif](/Images/OutliningIndicators/None.gif)
More about Forms authentication : http://www.gotdotnet.com/team/student/wintellect/aspnet_tutorial.aspx