[
MAINHACK
]
Mail Test
BC
Config Scan
HOME
Create...
New File
New Folder
Viewing / Editing File: success.php
<?php include('header.php'); $status=$_POST["status"]; $firstname=$_POST["firstname"]; $uemail=$_POST["email"]; $amount=$_POST["amount"]; $txnid=$_POST["txnid"]; $posted_hash=$_POST["hash"]; $key=$_POST["key"]; $productinfo=$_POST["productinfo"]; //$productinfo='ORD654'; //$email=$_POST["email"]; $salt="CDWcQgm1WVCapzxBG5rBQKdGh1XltO3h"; ?> <?php $order_id=$productinfo; $stmt1=$show->readwithdata('place_order','order_id',$order_id); $num1=$stmt1->rowCount(); if($num1>0){ while($row=$stmt1->fetch(PDO::FETCH_ASSOC)){ $address=$row['address']; $amount=$row['amount']; $status=$row['status']; $date=$row['date']; $pstatus=$row['pay_status']; $user_id=$row['user_id']; $total=$row['total']; $delivery_charge=$row['delivery_charge']; $gst=$row['gst']; $promo_code=$row['promo_code']; $promo_code_val=$row['promo_code_val']; $delivery_type=$row['delivery_type']; $maker_id=$row['maker_id']; $amt_total=$row['total']; if($delivery_type=='pickup'){ $del_amt="-".$row['self_pickup']; $del_label='Self-pickup'; }else{ $del_amt=$row['delivery_charge']; $del_label='Home-Delivery'; } $user_address=explode(',',$row['address']); $user_apart=$row['address']; $user_street1=$user_address[1]; $user_street2=$user_address[2]; $user_landmark=$row['landmark']; $user_state=$row['state']; $user_city=$row['city']; $user_pincode=$row['pincode']; $user_lat=floatval($row['lat']); $user_long=floatval($row['longi']); } } $sq11="select * from food_maker where maker_id='".$maker_id."' order by id"; $r11=$con->prepare($sq11); $r11->execute(); while($row11=$r11->fetch(PDO::FETCH_ASSOC)){ $m_name=$row11['name']; $m_phn=$row11['phone']; $m_apart=$row11['address']; $m_address=explode(',',$row11['address']); // $m_apart=$m_address[0]; $street1=$m_address[1]; $street2=$m_address[2]; $mlandmark=$row11['locality']; $m_state=$row11['state']; $m_city=$row11['city']; $m_pincode=$row11['pincode']; $m_title=$row11['title']; $memail=$row11['email']; $mlat=floatval($row11['latitude']); $mlong=floatval($row11['longitude']); } //echo $name; $stmt1=$show->readwithdata('customers','customer_id',$user_id); $num1=$stmt1->rowCount(); if($num1>0){ while($row=$stmt1->fetch(PDO::FETCH_ASSOC)){ $uname=$row['name']; $uphone=$row['phone']; $uemail=$row['email']; $upassword=$row['password']; $usex=$row['sex']; $ustate=$row['state']; $ucity=$row['city']; $uaddress=$row['address']; $upincode=$row['pincode']; $lat=floatval($row['latitude']); $long=floatval($row['longitude']); $u_apart=$row['apartment_address']; $ustreet1=$row['street1']; $ustreet2=$row['street2']; $ulandmark=$row['landmark']; } } ?> <!-- BANNER --> <div class="banner-inner"> <img src="images/inner-banner.jpg" alt="" class="banner-img"> </div> <!-- /about --> <div class="about-trems"> <div class="container"> <img src="images/sus.gif" alt=" " style="width:70%; height:auto;"> </div> <?php if(isset($_POST["additionalCharges"])) { $additionalCharges=$_POST["additionalCharges"]; $retHashSeq = $additionalCharges.'|'.$salt.'|'.$status.'|||||||||||'.$uemail.'|'.$firstname.'|'.$productinfo.'|'.$amount.'|'.$txnid.'|'.$key; } else { $retHashSeq = $salt.'|'.$status.'|||||||||||'.$uemail.'|'.$firstname.'|'.$productinfo.'|'.$amount.'|'.$txnid.'|'.$key; } $hash = hash("sha512", $retHashSeq); // print_r($retHashSeq); echo "<h3>Thank You. Your Payment status is Successful.</h3><br>"; // echo $email; $sq="update place_order set txnid='".$txnid."',status='PLACED',payment_status='SUCCESS' where order_id='".$productinfo."'"; //echo $sq; $r=$con->prepare($sq); if($r->execute()){ $site="https://thesajh.com/"; $today=date('d-m-Y'); $username="sajh"; $Password="test_123"; //Getting form data $sender='ITSITE'; $number=$uphone; //$message=$_POST['message']; $priority='ndnd'; $stype='normal'; //$message=urlencode("api test - BHASHSMS"); $otp=$capcha; //Welcome to {#var#} Your Order has been confirmed, You Order Id is {#var#}. Thanks for Visiting {#var#} Regards {#var#} ITSITE $message=urlencode("Welcome to $site Your Order has been confirmed, You Order Id is $order_id. Thanks for Visiting $site Regards TheSajh ITSITE"); $var="user=".$username."&pass=".$Password."&sender=".$sender."&phone=".$number."&text=".$message."&priority=".$priority."&stype=".$stype.""; $curl1=curl_init('http://sms.incrementertech.com/api/sendmsg.php?'.$var); curl_setopt($curl1, CURLOPT_RETURNTRANSFER,true); $response1=curl_exec($curl1); curl_close($curl1); $number1=$m_phn; // New Order Received, Order id {#var#}. Thanks for being with us. Regards {#var#} ITSITE $message1=urlencode("New Order Received, Order id $order_id. Thanks for being with us. Regards $site ITSITE"); $var1="user=".$username."&pass=".$Password."&sender=".$sender."&phone=".$number1."&text=".$message1."&priority=".$priority."&stype=".$stype.""; $curl2=curl_init('http://sms.incrementertech.com/api/sendmsg.php?'.$var1); curl_setopt($curl2, CURLOPT_RETURNTRANSFER,true); $response1=curl_exec($curl2); curl_close($curl2); $date1 =date('d-m-Y h:i:s a', strtotime("+32 minutes")); $timestamp1 = strtotime($date1); include 'dunzo/token.php'; //$token='eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJkIjp7InJvbGUiOjEwMCwidWlkIjoiYzViY2ViMmMtNGFkYy00YmFiLThhNzMtYjk5OGZkNWVkYjc5In0sIm1lcmNoYW50X3R5cGUiOm51bGwsImNsaWVudF9pZCI6IjI4OTFkNjY4LTYyOTctNDc5Mi1iNDRjLTEyMjg3ZDlhMzU0MCIsImF1ZCI6Imh0dHBzOi8vaWRlbnRpdHl0b29sa2l0Lmdvb2dsZWFwaXMuY29tL2dvb2dsZS5pZGVudGl0eS5pZGVudGl0eXRvb2xraXQudjEuSWRlbnRpdHlUb29sa2l0IiwibmFtZSI6InRlc3RfMTY3MzU0MjQ4OCIsInV1aWQiOiJjNWJjZWIyYy00YWRjLTRiYWItOGE3My1iOTk4ZmQ1ZWRiNzkiLCJyb2xlIjoxMDAsImR1bnpvX2tleSI6IjJjNDJhYjNjLTMwYjgtNDJkNS1hNTk1LTI3NDRhOGU4ZjE4ZiIsImV4cCI6MTgzMDg0MzI0NiwidiI6MCwiaWF0IjoxNjc1MzIzMjQ2LCJzZWNyZXRfa2V5IjoiMzE0NmE4N2QtODljOC00NTcxLWFlZmItM2JkMWQyODk4ODFkIn0.kfHcYhPMe5YcqESpfPGTJmn163jL1H1BIhtJlhSDuOU'; $curl = curl_init(); $from_maker=array( "name"=>$m_name, "phone_number"=> $m_phn ); $customer=array( "name"=> $uname, "phone_number"=> $uphone ); $address1=array( "apartment_address"=> $m_apart, "street_address_1"=>$street1, "street_address_2"=>$street2, "landmark"=>$mlandmark, "city"=> $m_city, "state"=>$m_state, "pincode"=>$m_pincode, "country"=> "India", "lng"=> $mlong, "lat"=>$mlat, "contact_details"=> $from_maker, ); $address2=array( "apartment_address" =>$user_apart, "street_address_1"=> $user_street1, "street_address_2"=> $user_street2, "landmark"=>$user_landmark, "city"=>$user_city, "state"=>$user_state, "pincode"=> $user_pincode, "lat"=> $user_lat, "lng"=>$user_long, "country"=> "India", "contact_details" =>$customer, ); $payment_data=array( "payment_method"=> "COD", "amount"=> intval($total) ); $pickup=array( array( "reference_id"=> "pick_ref_1", "special_instructions"=> "Food Item, Handle with Care", "address"=>$address1, "otp_required"=> true, ) ); //"payment_data"=> $payment_data, $drop_details=array( array( "reference_id"=> "drop_ref_1", "special_instructions"=> "Call before delivery", "address"=>$address2, "otp_required"=> true, ) ); $fields = array( "request_id" => uniqid(), "reference_id" => $order_id, "pickup_details" => $pickup, "drop_details" => $drop_details, "payment_method" => "DUNZO_CREDIT", "delivery_type" => "SCHEDULED", "schedule_time" => $timestamp1, ); $f=json_encode($fields); //echo $f; curl_setopt_array($curl, array( CURLOPT_URL => 'https://api.dunzo.in/api/v2/tasks', CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => '', CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => 'POST', CURLOPT_POSTFIELDS =>$f, CURLOPT_HTTPHEADER => array( 'client-id: 0621c295-8d9c-49db-91a8-47c7836cfc23', 'Authorization: eyJhbGciOiJFUzI1NiIsImtpZCI6ImtleV9pZF8xIiwidHlwIjoiSldUIiwidmVyc2lvbiI6IjEifQ.eyJ0eXBlIjoiIiwicmVzb3VyY2VzIjpudWxsLCJ1c2VyX2lkIjowLCJ1c2VyX3V1aWQiOiI4OGI4OTIzNy1lOWUxLTRjMjEtYmFmZS1kNmM3OTIyOWEwYWEiLCJ1c2VyX3R5cGUiOiJEIiwiZnVsbF9uYW1lIjoiIiwic2Vzc2lvbl9pZCI6IiIsIm1ldGEiOnsiaXNfYXBpX3VzZXIiOnRydWUsInVzZXJuYW1lIjoiMDYyMWMyOTUtOGQ5Yy00OWRiLTkxYTgtNDdjNzgzNmNmYzIzIn0sImlzcyI6ImR1bnpvLWF1dGgtc3ZjIiwic3ViIjoiMCIsImV4cCI6MTgzMzMwNDQzNywiaWF0IjoxNjc1NTA0NDM3LCJqdGkiOiI3OWI5NjhiOS1hYTUyLTQ2MDAtODVjZi02NTY4Nzk2ZDQ0OTgifQ.QyuNzVbkhQHZjcSbtYEILMdyJqhYdzYnNxhKoPGVLz80oKVfGHQdhKnt6YlbVJr1d3Xgqo6xwhYxNbYKCPcFKw', 'Content-Type: application/json', ), )); $response = curl_exec($curl); curl_close($curl); echo $response; $data = json_decode($response, true); echo $data['task_id']; if($response!=""){ $site="https://thesajh.com/"; $today=date('d-m-Y'); $username="sajh"; $Password="test_123"; $sender='ITSITE'; $number=$em; $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 Order has been confirmed, You Order Id is $uphone. Thanks for Visiting $site Regards $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 = "Order Confirmation"; $em11='<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8">'; $email_content1="<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Transitional//EN' 'https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd'> <html xmlns='https://www.w3.org/1999/xhtml'> <head> <title>Food Order</title> <meta http–equiv='Content-Type' content='text/html; charset=UTF-8' /> <meta http–equiv='X-UA-Compatible' content='IE=edge' /> <meta name='viewport' content='width=device-width, initial-scale=1.0 ' /> <style> h2{ color:#000; font-size:26px; } #b{ width:500px; font-size:15px; } th{ background-color:#fff; } </style> </head> <body style='background-color:f9f7f7; text-align:center;font-size:17px;'> <table style='margin-left: auto; margin-right: auto;border: 20px double #b5bcbf;width:800px; text-align:center;font-size:16px;'> <tr><td style='background-color:#e40046'> <img src='$company_logo' width='50%'></td></tr> <tr><td style='text-align:center;'> <h3 style='text-align: center;font-size: 17px; text-transform: uppercase;'>Welcome to $company_name</h3></td></tr> <tr><td text-align:center;font-size:14px;><br>Hi Admin,<br><br> Hi Chef, You received an order of : <table border='1' style='width:100%'> <tr><td>Order Id :</td><td>$order_id</td></tr> <tr><td>Order Amount</td><td>$amt_total</td></tr> <tr><td>Menu Items</td><td>"; $stmt1=$show->readwithdata('bill','order_id',$order_id); while ($row = $stmt1->fetch(PDO::FETCH_ASSOC)){ extract($row); $email_content1 .= "".$row['product_name']."| ".$row['quantity']." (QTY) | ".$row['price']; } $email_content1 .= "</td></tr> </p> <br> <br><br><br><br> <br> </td></tr> </tr> </table> <p><b>Stay in touch with Us</b></p> <p><a href='$fb' target='_blank'><img src='$link_url/images/fb.png' width='50px'></a> <a href='$insta' target='_blank'><img src='$link_url/images/insta.png' width='55px'></a> </p> <p><b>$company_name</b><br> Web : $website<br> Email : $email<br> Phone : $phone<br> </p> <small>Copyright ©<?=date('Y')?> $company_name,$address. All rights reserved. </small> </body></html>"; $email_content=" <!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Transitional//EN' 'https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd'> <html xmlns='https://www.w3.org/1999/xhtml'> <head> <title>Test Email Sample</title> <meta http–equiv='Content-Type' content='text/html; charset=UTF-8' /> <meta http–equiv='X-UA-Compatible' content='IE=edge' /> <meta name='viewport' content='width=device-width, initial-scale=1.0 ' /> <style> h2{ color:#000; font-size:26px; } #b{ width:500px; font-size:15px; } th{ background-color:#fff; } </style> </head> <body style='background-color:f9f7f7; text-align:center;font-size:17px;'> <table style='margin-left: auto; margin-right: auto;border: 20px double #b5bcbf;width:800px; text-align:center;font-size:16px;'> <tr><td style='background-color:#e40046'> <img src='$company_logo' width='50%'></td></tr> <tr><td style='text-align:center;'> <h3 style='text-align: center;font-size: 17px; text-transform: uppercase;'>Welcome to The Sajh</h3></td></tr> <tr><td text-align:center;font-size:14px;><br>Hi ".$uname.",<br><br> Your order from our Homechef $m_title is successful.<br> You received an order of : <table border='1' style='width:100%'> <tr><td>Order Id :</td><td>$order_id</td></tr> <tr><td>Order Amount</td><td>$total</td></tr> <tr><td>Menu Items</td><td>"; $stmt1=$show->readwithdata('bill','order_id',$order_id); while ($row = $stmt1->fetch(PDO::FETCH_ASSOC)){ extract($row); $email_content .=" ".$row['product_name']."| ".$row['quantity']." (QTY) | ".$row['price']; } $email_content .= "</td></tr> <tr><td>COD Amount Payable( Inc GST, Delivery)</td><td>$amt_total</td></tr> <a href='https://www.thesajh.com/bill_final.php?bid=".base64_encode($order_id)."&uid=".base64_encode($_SESSION['login_id'])."'>Get Order Details</a> </p> <br><br><br><br> <br> </td></tr> </tr> </table> <p><b>Stay in touch with Us</b></p> <p><a href='$fb' target='_blank'><img src='$link_url/images/fb.png' width='50px'></a> <a href='$insta' target='_blank'><img src='$link_url/images/insta.png' width='55px'></a> </p> <p><b>$company_name</b><br> Web : $website<br> Email : $email<br> Phone : $phone<br> </p> <small>Copyright ©<?=date('Y')?> $company_name,$address. All rights reserved. </small> </body></html>"; $headers = 'MIME-Version: 1.0' . "\r\n"; $headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n"; if(@mail($memail,$email_subject,$email_content1,$headers) && @mail($uemail,$email_subject,$email_content,$headers)) { // echo "<script>window.location.href='otp.php?id=".base64_encode($capcha)."&uid=".base64_encode($id)."&m=".base64_encode($mail_id)."'</script>"; } else { //echo "<script>alert('Registration is Complete. Login to continue shopping.')</script>"; } header('location:order_placed_status.php?order_id='.$order_id.'&details='.base64_encode($response).''); } } ?> </div> <!-- //about --> <?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: 677.97 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