[
MAINHACK
]
Mail Test
BC
Config Scan
HOME
Create...
New File
New Folder
Viewing / Editing File: forget.php
<!-- Header include --> <?php include("header.php"); ?> <!-- Inner-banner --> <div class="inner-banner"> <img src="images/inner-banner-6.png"> <div class="container"> <h1>Forget</h1> </div> </div> <div class="log-in-block"> <div class="container"> <div class="log-in-box-content"> <div class="log-left"> <form method="post" enctype= "multipart/form-data"> <h4>Forget Password</h4> <p>Enter your registered email to reset your password</p> <div class="fill-form"> <i class="fa-solid fa-user"></i> <input type="email" name="email" placeholder="Email"> <input type="hidden" name="table" value="apartment"> </div> <div class="fill-form"> <i class="fa-solid fa-user"></i> <input type="text" name="phone" placeholder="Phone" maxlength="10"> </div> <div class="fill-form log-in-btn"> <input type="submit" value="Submit" name="forget_pass"> </div> </form> <?php if(isset($_POST['forget_pass'])){ $sq="select email,phone from ".$_POST['table']." where email='".trim($_POST['email'])."' and phone='".trim($_POST['phone'])."'"; $stmt=$con->prepare($sq); $stmt->execute(); $num1=$stmt->rowCount(); /* $stmt=$show->readwithdata('client','phone',$_POST['phone']); $num1=$stmt->rowCount();*/ if($num1>0){ $no=rand(1,10000); $capcha=$no; $my_mail=$_POST['email']; $user=$_POST['email']; /* $apiKey = urlencode('MzQ2NTM3Mzg3MDcyNjQ0ZDZiNGI0MjRmMzgzNzQ3NTQ='); // Message details $numbers =htmlentities(strip_tags($_POST['phone'])); $sender = urlencode('STPLDW'); $message = rawurlencode(''.$capcha.'is your Doctorwala password reset code. STPLDW'); // $numbers = implode(',', $numbers); // Prepare data for POST request $data = array('apikey' => $apiKey, 'numbers' => $numbers, "sender" => $sender, "message" => $message); // Send the POST request with cURL $ch = curl_init('https://api.textlocal.in/send/'); curl_setopt($ch, CURLOPT_POST, true); curl_setopt($ch, CURLOPT_POSTFIELDS, $data); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $response = curl_exec($ch); curl_close($ch); */ /* $site="https://thesajh.com/"; $today=date('d-m-Y'); $username="sajh"; $Password="test_123"; $sender='ITSITE'; $number=$my_mail; $priority='ndnd'; $stype='normal'; $otp=$capcha; //Welcome to {#var#} Your OTP to Reset your Password is {#var#}. OTP is valid for 5mins only. Thanks for Visiting {#var#} ITSITE $message=urlencode("Welcome to $site Your OTP to Reset your Password is $otp. OTP is valid for 5mins only. Thanks for Visiting $site ITSITE"); $var="user=".$username."&pass=".$Password."&sender=".$sender."&phone=".$number."&text=".$message."&priority=".$priority."&stype=".$stype.""; $curl=curl_init('http://sms.incrementertech.com/api/sendmsg.php?'.$var); curl_setopt($curl, CURLOPT_RETURNTRANSFER,true); $response=curl_exec($curl); curl_close($curl); */ $email_subject = "Reset Password-OTP"; $emcc='<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8">'; $email_content="<html><head> <style> h2{ color:#000; font-size:26px; } #b{ width:500px; font-size:15px; } th{ background-color:#fff; } </style> </head> <body> <table style='border: 40px solid #000;width=800px;'> <hr> <h3>Welcome to $company_name </h3></td></tr> <tr><td style='text-align:justify;padding:12px;font-size:18px;'><br>Hi ,<br><br> Your OTP for reset password is : ".$capcha."<br><br> Please visit this link and verify your OTP and reset the password. <br> <a href='https://itsweb.in/demobyITS/YaarYards7/reset_password.php?id=".base64_encode($capcha)."&m=".base64_encode($_POST['email'])."&tab=".base64_encode($_POST['table'])."&p=".base64_encode($_POST['phone'])."'>Change Password</a> <br><br><br><br> Thanks & Regards,<br> Team $company_name,<br> Web : $website<br> Email :$email<br> <br> <br> </td></tr> </tr> </table> </body></html>"; $headers = 'MIME-Version: 1.0' . "\r\n"; $headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n"; if(@mail($my_mail,$email_subject,$email_content,$headers)) { echo '<script> setTimeout(function() { swal({ title: "Thank You!", text: "OTP has been sent to your registered mail/phone no", type: "success" }, function() { window.location = "reset_password.php?id='.base64_encode($capcha).'&m='.base64_encode($_POST["email"]).'&tab='.base64_encode($_POST['table']).'&p='.base64_encode($_POST['phone']).'"; }); }, 1000); </script>'; } }else{ echo "<script>swal('Please check your email and phone No entered.')</script>"; } } ?> </div> <div class="log-right"> <img src="images/login.gif"> </div> </div> </div> </div> <!-- Footer include --> <?php include("footer.php"); ?>
Save Changes
Cancel / Back
Close ×
Server Info
Hostname: server05.hostinghome.co.in
Server IP: 192.168.74.40
PHP Version: 7.4.33
Server Software: Apache
System: Linux server05.hostinghome.co.in 3.10.0-962.3.2.lve1.5.81.el7.x86_64 #1 SMP Wed May 31 10:36:47 UTC 2023 x86_64
HDD Total: 1.95 TB
HDD Free: 678.04 GB
Domains on IP: N/A (Requires external lookup)
System Features
Safe Mode:
Off
disable_functions:
None
allow_url_fopen:
On
allow_url_include:
Off
magic_quotes_gpc:
Off
register_globals:
Off
open_basedir:
None
cURL:
Enabled
ZipArchive:
Disabled
MySQLi:
Enabled
PDO:
Enabled
wget:
Yes
curl (cmd):
Yes
perl:
Yes
python:
Yes
gcc:
Yes
pkexec:
No
git:
Yes
User Info
Username: itsweb
User ID (UID): 1619
Group ID (GID): 1621
Script Owner UID: 1619
Current Dir Owner: 1619