Login and logout programmatically?

Vote:
 

Does anyone know how I can login and logout a user through code in EPiServer 5? I'm refering to formsauth. Does EPi use the regular .net functionality for this?

#25094
Oct 13, 2008 15:02
Vote:
 

Login: System.Web.Security.FormsAuthentication.SetAuthCookie("username", true/false);

Logout:  System.Web.Security.FormsAuthentication.SignOut();

#25097
Oct 13, 2008 15:15
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.