| Server IP : 10.200.247.200 / Your IP : 216.73.217.19 Web Server : Apache System : Linux synergy-usa-sites 6.8.0-138-generic #138-Ubuntu SMP PREEMPT_DYNAMIC Fri Jul 31 22:41:49 UTC 2026 x86_64 User : jeremy ( 1001) PHP Version : 8.4.25 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /var/www/usa_sites/usagrantapplications.org/ |
Upload File : |
<?php
$error='';
if (isset($_POST['submitted']))
{
$email=$_POST['email'];
require_once('inc/db_config.php');
require_once('inc/common.php');
require_once('inc/Db.php');
if ($email=='' || ! eregi("^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$", $email))
$error='Please type in a valid email address.';
else
{
$Db=New Db_Class;
$email=trim(mysql_real_escape_string($email));
$sql="SELECT 1 FROM lc_reseller WHERE email='$email'";
$Db->query($sql);
if ($Db->num_rows() <= 0)
$error='The email address <b>'.$email.'</b> was not found in our database.';
}
if ($error=='')
{
$sql="SELECT id, first, last FROM lc_reseller WHERE email='$email'";
$Db->query($sql);
$id=$Db->getSingle('id');
$first=$Db->getSingle('first');
$last=$Db->getSingle('last');
$to=trim($email);
$code=md5($id.$to);
$subject='Password Recovery Request [USAGrantApplications.org]';
$msg="Dear $first,
Someone requested your password at USAGrantApplications.org to be reset. If you made this request and would like to change your password, click the link below:
http://www.usagrantapplications.org/reset.php?i=$id&c=$code
If you didn't make this request, simply ignore this email.
Regards,
USAGrantApplications.org.
";
$headers = 'From: support@USAGrantApplications.org' . "\r\n" .
'Reply-To: support@USAGrantApplications.org' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
mail($to,$subject,$msg,$headers);
$sent=true;
}
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Federal Grant Finder - Recover Login Page</title>
<link href="cssstyles.css" type="text/css" rel="stylesheet" />
</head>
<body style="text-align:center">
<form method="post" action="recover.php">
<table cellpadding="0" cellspacing="0" width="790" align="center">
<tr><td width="790" height="55" background="images/smltop.gif" style="text-indent:80px;background-repeat:no-repeat"><font face="Myriad Pro, Verdana, Arial, Helvetica, sans-serif" color="#FFFFFF" size="5"><strong>Recover Login Page</strong></font></td></tr>
<tr><td style="border-left:1px solid #007bc2;border-right:1px solid #007bc2" align="left">
<div style="padding:10px">
<? if ($sent) : ?>
<b style="color:green;">
Please check your email at <?=$to;?> for instructions on how to reset your password.
</b>
</div>
<? die;?>
<? endif;?>
<font size="2" face="Verdana, Arial, Helvetica, sans-serif" color="#333333"><p><font size="4" face="Verdana, Arial, Helvetica, sans-serif"><strong>Forgot your Login?</strong></font></p><p>Input your email address below and we'll email your password.</p></font>
<? if ($error !='') : ?>
<span style="color:red;"><?=$error;?></span><br />
<? endif;?>
</div>
<div align="center">
<table>
<tr><td><font size="2" face="Verdana, Arial, Helvetica, sans-serif">Email Address:</font></td><td id="form"><input type="text" size="30" name="email" value="<?=$_POST['email'];?>" /></td><td align="center" width="150px"><center><input type="submit" value=" Retrieve Login " name="submitted" style="cursor:pointer" /></center></td></tr>
</table>
</div>
<br />
<br />
<br />
</td></tr>
</table><br />
<br />
</form>
</body>
</html>