LoginStatus Control Example
Example Summary and Logic
The LoginStatus control renders just a single <span> tag whose CSS class can be set using
the LoginStatus' CssClass property. In the unadapted form, the <span> includes an inline
style to set the border-width (zero by default). If you eschew inline styles, you can adapt the
LoginStatus control to omit the style attribute on the <span>.
This is a good example of using adapters to fine tune your rendered markup. Not all adapters have to result
in massive changes to the markup like you see with the Menu
or TreeView adapters. It's perfectly reasonable to use adapters
to make smaller changes, too.
If the user is logged in, the logout link is displayed. Otherwise, the login link is shown.
In both cases, the link goes to the login page.
What would you like to do next?