djr33 is right, I thought you were storing alot of users for your website.
Also, after they have logged in, you can use sessions to store the password, so it does not have to be in a "POST" method all the time.
PHP Code:
$fp = fopen('flat-file-data.txt','r');
$line = fgets($fp, 1024);
list ($passwordlvl1, $passwordlvl2, $passwordlvl3) = split ('\|', $line);
if($_SESSION['password']==$passwordlvl1)
{
//password #1
}
elseif($_SESSION['password']==$passwordlvl2)
{
//password #2
}
elseif($_SESSION['password']==$passwordlvl3)
{
//password #3
}
else
{
header("location: login.php");
}
-untested
The $_SESSION['password'] would have to be set by the login script.
Bookmarks