Display a link to login or logout. |
|
| see zena 1.0 | |
Display a “login” or “logout” link. The login link points to the current page with authenticated prefix (oo):
<r:login_link/>
Use custom messages for login and logout by using the block syntax:
<r:login_link> <r:t>sign in</r:t> <r:else do='t'>sign out</r:else> </r:login_link>
Finally, if you need something very special, you can also use login_url and logout_url with a custom if clause:
<r:if test='visitor.is_anon?'> <a href='#{login_url}' do='t'>sign in</a> <a do='else' href='#{logout_url}' do='t'>sign out</a> </r:if>