44 - ASP.NET LoginStatus Control

Опубликовано: 18 Июнь 2026
на канале: easyaspnet
8,205
8

The LoginStatus control is a very simple control, all it does is display a link which is different depending on whether the user is logged in or logged out. If a user is logged in then it displays a Log Out link and vice versa. There are few properties that it supports, LogOutAction can be used to specify what happen when a user clicks on the Log Out link. 3 options are Redirect, RedirectToLoginPage and Refresh. If you set it to Redirect then you must set another property LogOutPageUrl which a user is redirected to after logging out of the website.