Log In System: DWMX 2004
The first screen the user will see is the sign in our log in page.
Creating the sign in page
- Open the login.php page.
- Insert a form; name the form login_sys.
- Make a table within the form with 3 rows and 2 columns.
- In the left-hand column, type in the top row User Name:
- In the left-hand column, middle row, type Password:
- In the right-hand top column insert a text field. Name it username.
- In the right-hand middle row insert a text field and name it password Choose the radio button for the password type. You can also add a max char in each field to match the max char in the database, if you like.
- Add a button, and change the label to Log In.

- Select the “Login” button. Add the Login Server Behavior. Go to Window>Server Behaviors. Choose the plus sign and find User Authentication>Login User.
- Dreamweaver MX 2004 is pretty smart about finding the correct data to enter once you choose the connection and table. Make sure that the username points to the username field in your database, and that the password points to the password field in your database.
- If the log in succeeds (there is a username and password to match in your database), the script will send the user to a members-only page that we have named restricted.php. If the login fails (typos or not a valid user), the script sends the visitor to the sorry.php page.

Now we'll set up the restricted, sorry, and admin pages-->