MTDW001: Simple Forms Authentication - Tutorial 5
Step 10 - Adding the logout behaviour:
When we have finished browsing secured pages, we will want to end the session to logout. Open the target_page.aspx and add a form as for the login.aspx page:

Locate the logout behaviour on the server behaviours menu - MiArt> Forms Authentication>Web.config Style Forms Logout, click it and the following pop up menu appears:
The redirect page is the page where the user is sent after logging out. Click ok. The secure system is almost complete, we just need to add usernames and passwords.
Step 11 - Adding and deleting users:
Users are stored in the web.config file in the site root. This is an XML file, the portion that needs concern us here is the tag:
<username name="test" password="test" />
You should change the values "test" on a live site. Additional users can then be added by the method below:
Now we have completed our forms authenitication pages - open your start page in a browser window - click on the link to your target page - you will then see the login page: enter the username and password you have set in the web.config file, and then click "login" and you will be taken to your target page in the secure folder.
[Previous]



