Code: Select all
<?php
include("include/dbconnect.php");
include("include/settings.php");
$recover=mysql_query("SELECT name, user, pass FROM models WHERE email = '$email'");
$subject='Log In Info';
$row = mysql_fetch_assoc($recover);
if ($row == "")
{
echo "The email address you submitted was not found in our database. Check to make sure you entered in the address in correctly.";
}
else
{
$mesaj = "From time to time people forget many things, dont feel bad. Your information is listed below.\n\nUsername: $row[user]\nPassword: $row[pass]";
mail($email, $subject , $mesaj ,"From: webmaster@reddragonmodels.net\nReply-To: webmaster@reddragonmodels.net\n");
}
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<body>
<?php include("header.php"); ?>
<?php print "$row[name],\n"; ?><br><br>
<font size="+1"><b>Your Username and password has been sent<br> to the email account your registered with.</b></font><br>
</body>
</html>