Jack Nilan         Intro to PHP        EMail : jacknilan@yahoo.com

You can use a password to redirect people to your page

Here is a form to let you enter your password. You can view the source. The page will send your password to password.php. On that page you check to se if it the correct password. If it is then you send them on to your page. If it isn't the right password them you send them to an error page.

The code below is the PHP to receive the password and check the password

<?php
$p = $_POST['pass'];
if ($p =="Joe")
{echo "<meta http-equiv='refresh' content='0;url=http://www.phpeasystep.com'>";
} else
{echo "<meta http-equiv='refresh' content='0;url=http://www.yahoo.com'>";
}
?>