add all files

This commit is contained in:
Rucus
2026-02-17 09:29:34 -06:00
parent b8c8d67c67
commit 782d203799
21925 changed files with 2433086 additions and 0 deletions

View File

@@ -0,0 +1,49 @@
<?php
require_once('db.php');
include('functions.php');
if(isset($_POST['Submit']))
{
if($_POST['email']!='' && valid_email($_POST['email'])==TRUE)
{
$getUser = mysql_query('SELECT ID, Username, Temp_pass, Email FROM users WHERE Email = "'.mysql_real_escape_string($_POST['email']).'"');
if(mysql_num_rows($getUser)==1)
{
$temp_pass = random_string('alnum', 12);
$row = mysql_fetch_assoc($getUser);
$query = mysql_query("UPDATE users SET Temp_pass='".$temp_pass."', Temp_pass_active=1 WHERE `Email`='".mysql_real_escape_string($row['Email'])."'");
$headers = 'From: webmaster@ourdomainhere.com' . "\r\n" .
'Reply-To: webmaster@ourdomainhere.com' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
$subject = "Password Reset Request";
$message = "Dear ".$row['Username'].", Someone (presumably you), has requested a password reset. We have generated a new password for you to access our website: $temp_pass . To confirm this change and activate your new password please follow this link to our website: http://www.ourdomainhere.com/confirm_password.php?ID=".$row['ID']."&new=".$temp_pass.". Don't forget to update your profile as well after confirming this change and create a new password. If you did not initiate this request, simply disregard this email, and we're sorry for bothering you.";
if(mail($row['Email'], $subject, $message, $headers))
{
$msg = 'Password reset request sent. Please check your email for instructions.';
}
else {
$error = 'Failed sending email';
}
}
else {
$error = 'There is no member to match your email.';
}
}
else {
$error = 'Invalid email !';
}
}
?>
<?php if(isset($error)){ echo $error;}?>
<?php if(isset($msg)){ echo $msg;} else {//if we have a mesage we don't need this form again.?>
<form action="<?=$_SERVER['PHP_SELF']?>" method="post">
<input type="text" id="email" name="email" size="32" value="" />
<input type="submit" name="Submit" value="Submit" />
</form>
<? } ?>