O Xabarin
2008-07-12 11:15:51 UTC
//Checks if there is a login cookie
if(isset($_COOKIE['ID_my_site']))
//if there is, it logs you in and directs you to the members page<--I changed one line of code here from the original script
{
$username = $_COOKIE['ID_my_site'];
$pass = $_COOKIE['Key_my_site'];
$check = mysql_query("SELECT * FROM users WHERE username = '$username'")or die(mysql_error());
while($info = mysql_fetch_array( $check ))
{
if ($pass != $info['password'])
{
}
else
{
echo "Welcome " . $_COOKIE['ID_my_site'];
}
}
}