to implement the log out functionality in asp.net application use the following code in the body of log out button event handler
Session.Clear();
Session.Abandon();
Response.Clear();
Response.Redirect(context.LoginPage);
and to prevent back feature of the browser or accessing the website after log out using the following line
HttpContext.Current.Response.Cache.SetExpires(DateTime.Now);
Tuesday, December 8, 2009
Subscribe to:
Post Comments (Atom)

No comments:
Post a Comment