HTML tutorial
CSS3 tutorial
Bootstrap tutorial
JavaScript tutorial
JQuery tutorial
AngularJS tutorial
React tutorial
NodeJS tutorial
PHP tutorial
Python tutorial
Python3 tutorial
Django tutorial
Linux tutorial
Docker tutorial
Ruby tutorial
Java tutorial
C tutorial
C ++ tutorial
Perl tutorial
JSP tutorial
Lua tutorial
Scala tutorial
Go tutorial
ASP.NET tutorial
C # tutorial
The Logout() method logs out the current user. "
The Logout() method logs out the current user.
// Log out the current user
WebSecurity.Logout();
//
Redirect back to the homepage
Response.Redirect("~/");
' Log out the current user
WebSecurity.Logout()
'
Redirect back to the homepage
Response.Redirect("~/")
None.
None.
Any access to the WebSecurity object throws an InvalidOperationException if:
When a user is logged in, ASP.NET sets an authentication token in a cookie that lets ASP.NET know on subsequent requests that the user has been logged in.
The Logout() method removes the authentication token, which has the effect of logging the user out.
❮ WebSecurity