Файловый менеджер - Редактировать - /home/d46091/drivinglicencehelp.com/submit-backup.txt
Назад
<?php session_start(); ob_start(); include_once('config.php'); include_once('easebuzz-lib/easebuzz_payment_gateway.php'); date_default_timezone_set('Asia/Kolkata'); $date = date('d-m-Y H:i:s'); function generateTxnId($length = 7) { $chars = 'abcdefghijklmnopqrstuvwxyz1234567890'; $token = ''; while(strlen($token) < $length) { $token .= $chars[mt_rand(0, strlen($chars)-1)]; } return strtoupper('DL-2021-' . $token); } use PHPMailer\PHPMailer\PHPMailer; use PHPMailer\PHPMailer\Exception; require 'vendor/autoload.php'; $applicant_name = urlencode($_POST['applicant_name']); $mobile_number = urlencode($_POST['mobile_number']); $email_id = urlencode($_POST['email_id']); if(isset($_POST['state'])) { $state = urlencode($_POST['state']); } elseif(isset($_POST['office_state'])) { $state = urlencode($_POST['office_state']); }else{ $state = '-'; } if( (isset($_POST['form_id'])&& $_POST['form_id'] =='dl_licence_guide') ) { $_SESSION['table_id'] = 'licence_guide_book_form'; $payment_status = 'Unpaid'; $product_price = 525; if((isset($_POST['coupon'])) && ((strtoupper($_POST['coupon']) == 'OFFER200'))){ $product_price = 525 - 200; } $sql = " INSERT INTO licence_guide_book_form ( form_name, applying_for, applicant_name, mobile_number, email_id, address, state, district, landmark, pincode, total_amount, payment_status, form_created_on ) VALUES ( '".$_POST["form_name"]."', '".$_POST["applying_for"]."', '".$_POST["applicant_name"]."', '".$_POST["mobile_number"]."', '".$_POST["email_id"]."', '".$_POST["present_address"]."', '".$_POST["office_state"]."', '".$_POST["office_district"]."', '".$_POST["landmark"]."', '".$_POST["pincode"]."', '".$product_price."', '".$payment_status."', '".$date."' )"; if(!$result = $conn->query($sql)) { die('There was an error running the query [' . $conn->error . ']'); } else { $_SESSION["form_id"] = $conn->insert_id; $form_name = urlencode($_POST["form_name"]); $ch = curl_init('https://crm2.techlounge.co.in/api/registration-form-submission.php?formId='.$_SESSION["form_id"].'&vendor=TTG&business=DL&website=DRIVINGLICENCEHELP.COM&amount='.$product_price.'&status=Unpaid&name='.$applicant_name.'&mobile='.$mobile_number.'&email='.$email_id.'&state='.$state.'&formName='.$form_name.''); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $response = curl_exec($ch); curl_close($ch); $_SESSION["panel_form_id_2"] = $response; $_SESSION['form_name'] = $_POST['form_name']; $_SESSION['applicant_name'] = $_POST['applicant_name']; $_SESSION['mobile_number'] = $_POST['mobile_number']; $_SESSION['email_id'] = $_POST['email_id']; $_SESSION['total_amount'] = $product_price; $_SESSION['order_id'] = generateTxnId(17); include_once("editable/submit-form.php"); // Easebuzz Payment $easebuzzObj = new Easebuzz($MERCHANT_KEY, $SALT, $ENV); $postData = array ( "txnid" => "".$_SESSION['order_id']."", "amount" => "".$product_price.".00"."", "firstname" => "".$_POST["applicant_name"]."", "email" => "".$_POST["email_id"]."", "phone" => "".$_POST["mobile_number"]."", "productinfo" => "".$_POST["form_name"]."", "surl" => "https://drivinglicencehelp.com/response.php", "furl" => "https://drivinglicencehelp.com/response.php", "udf1" => "".$_SESSION["form_id"]."", "udf2" => "licence_guide_book_form", ); $easebuzzObj->initiatePaymentAPI($postData); // Mailer $mail = new PHPMailer(true); try { $mail->isSMTP(); $mail->Host = 'drivinglicencehelp.com'; $mail->SMTPAuth = true; $mail->Username = 'no-reply@drivinglicencehelp.com'; $mail->Password = 'freeDOM@611#'; $mail->SMTPSecure = 'tls'; $mail->Port = 587; $mail->setFrom("no-reply@drivinglicencehelp.com", "Driving Licence Registration"); $mail->addAddress("".$_POST["email_id"].""); $mail->isHTML(true); $mail->Subject = "Your ".$_POST["form_name"]." Submitted Successfully"; $mail->Body = " Dear <strong>".$_POST["applicant_name"]."</strong>, <br><br> Thank you for submitting your application for ".$_POST["form_name"]." on our website. <br><br> "; $mail->send(); $mail->ClearAllRecipients(); $mail->addAddress("no-reply@drivinglicencehelp.com"); $mail->isHTML(true); $mail->Subject = "New ".$_POST["form_name"]." Form Submitted"; $mail->Body = "APPLICANT NAME: ".$_POST["applicant_name"]."<br> MOBILE NUMBER: ".$_POST['mobile_number']."<br> EMAIL ID: ".$_POST['email_id']." "; $mail->send(); } catch (Exception $e) { echo "Message could not be sent. Mailer Error: {$mail->ErrorInfo}"; } } } // Enquiry if(isset($_POST["submit"])) { $sql=" INSERT INTO licence_guide_book_form ( form_name, applicant_name, mobile_number, email_id, form_created_on ) VALUES ( '".$_POST["form_name"]."', '".$_POST["applicant_name"]."', '".$_POST["mobile_number"]."', '".$_POST["email_id"]."', '".$date."' )"; if(!$result = $conn->query($sql)){ die('There was an error running the query [' . $conn->error . ']'); } else { $_SESSION["form_id"] = $conn->insert_id; $product_price = 'ENQUIRY'; $ch = curl_init('https://crm2.techlounge.co.in/api/registration-form-submission.php?formId='.$_SESSION["form_id"].'&vendor=TTG&business=DL&website=DRIVINGLICENCEHELP.COM&amount='.$product_price.'&status=Unpaid&name='.$applicant_name.'&mobile='.$mobile_number.'&email='.$email_id.'&state='.$state.''); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $response = curl_exec($ch); curl_close($ch); $_SESSION["panel_form_id_2"] = $response; $form_name = urlencode($_POST["form_name"]); // Mailer $mail = new PHPMailer(true); try { $mail->isSMTP(); $mail->Host = 'drivinglicencehelp.com'; $mail->SMTPAuth = true; $mail->Username = 'no-reply@drivinglicencehelp.com'; $mail->Password = 'freeDOM@611#'; $mail->SMTPSecure = 'tls'; $mail->Port = 587; $mail->setFrom("no-reply@drivinglicencehelp.com", "Driving Licence Registration"); $mail->addAddress("".$_POST["email_id"].""); $mail->isHTML(true); $mail->Subject = "Your ".$_POST["form_name"]." Submitted Successfully"; $mail->Body = " Dear <strong>".$_POST["applicant_name"]."</strong>, <br><br> Thank you for submitting your application for ".$_POST["form_name"]." on our website. <br><br> "; $mail->send(); $mail->ClearAllRecipients(); $mail->addAddress("no-reply@drivinglicencehelp.com"); $mail->isHTML(true); $mail->Subject = "New ".$_POST["form_name"]." Form Submitted"; $mail->Body = "APPLICANT NAME: ".$_POST["applicant_name"]."<br> MOBILE NUMBER: ".$_POST['mobile_number']."<br> EMAIL ID: ".$_POST['email_id']." "; $mail->send(); } catch (Exception $e) { echo "Message could not be sent. Mailer Error: {$mail->ErrorInfo}"; } echo "<script>alert('Thanks For submiting your enquiry form, Our Team Will assist you shortly.')</script>"; echo "<script>setTimeout(\"location.href = 'index.php';\",300);</script>"; } } ?>
| ver. 1.4 |
Github
|
.
| PHP 8.1.32 | Генерация страницы: 0 |
proxy
|
phpinfo
|
Настройка