Sindbad~EG File Manager

Current Path : /home/numerotech/www/tnoa-payments.tnoa.info/public/
Upload File :
Current File : //home/numerotech/www/tnoa-payments.tnoa.info/public/response-membership-test.php

<?php
    require_once 'AtomAES_V1.php'; 
    $atomenc = new AtomAES();
  
  
    $name 	    = "";
    $email	    = "";
    $mobile     = "";
    $amount     = "";
    $status     = "failure";
    $unique_id  = "";
    $payment_id = "";
    $method     = "";
  
?>
<!doctype html>
<html lang="en">
  <head>
    <title>Atom Paynetz</title>
    <!-- Required meta tags -->
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css">
  </head>
  <body>
      <?php
      
            $data = $_POST['encData'];
            
            $decrypted = $atomenc->decrypt($data, '75AEF0FA1B94B3C10D4F5B268F757F11', '75AEF0FA1B94B3C10D4F5B268F757F11');
            echo $decrypted;
            
            $jsonData = json_decode($decrypted, true);
          
            //   var_dump($jsonData)
            
            
      
            foreach($jsonData['payInstrument']['extras'] as $key=>$value)
            {
        	    
        	     if($key == "udf1")
        	     {
        	        $name = $value;
        	     }
        	     if($key == "udf2")
        	     {
        	        $email = $value;
        	     }
        	     if($key == "udf3")
        	     {
        	        $mobile = $value;
        	     }
        	}
        	
        	
        	foreach($jsonData['payInstrument']['payDetails'] as $key=>$value)
            {    
        	     if($key == "amount")
        	     {
        	        $amount = $value;
        	     }
        	     if($key == "atomTxnId")
        	     {
        	     	$payment_id = $value;
        	     }
        	}

            foreach($jsonData['payInstrument']['responseDetails'] as $key=>$value)
            {   
        	     if($key == "message")
        	     {
        	        $status = $value;
        	        
        	        if(isset($value) && $value == "SUCCESS")
        	        {
        	           $status = "success"; 
        	        }
        	        
        	        if (isset($value) && strpos($value , 'SUCCESS') )
        	        {
        	           $status = "success";
        	        }
        	        if( isset($value) && strpos($value, 'CANCELLED BY USER' ) ) 
        	        {
        	            $status = "cancelled_by_user";
        	        }
        	       // var_dump($status) ;exit();
        	     }
        	}
        	
        	foreach($jsonData['payInstrument']['merchDetails'] as $key=>$value)
            {   
        	     
        	     if($key == "merchTxnId")
        	     {
        	     	$unique_id = $value;
        	     }
        	}
        	
        	foreach($jsonData['payInstrument']['payModeSpecificData'] as $key=>$value)
            {   
        	     
        	     if($key == "subChannel")
        	     {
        	     	$method = $value[0];
        	     }
        	}

$res_url = "https://test-membership.numerotech.com/payment_server_response/3/tnoa/7";
// $res_url = "http://127.0.0.1:5003/payment_server_response/3/tnoa/7";


$url_1   = $res_url."?name=".$name."&email=".$email."&mobile=".$mobile."&amount=".$amount."&unique_id=".$unique_id."&payment_id=".$payment_id."&method=".$method."&status=".$status;
// 	 echo $url_1; exit();
    // $url_3 =  str_replace('https/', 'https://', $url_1);
    // echo $url_1;
     echo "<script>window.location.href='$url_1';</script>";
 	exit();


      
      
      ?>
      
      <div class="row pt-5">
         <div class="col-md-3"></div>
         <div class="col-md-3"><strong>Transaction result :</strong></div>
         <div class="col-md-3"><strong><?= $jsonData['payInstrument']['responseDetails']['message'] ?></strong></div>
         <div class="col-md-3"></div>
      </div>
      
       <div class="row pt-4">
         <div class="col-md-3"></div>
         <div class="col-md-3"><strong>Merchant transaction ID :</strong></div>
           <div class="col-md-3"><strong><?= $jsonData['payInstrument']['merchDetails']['merchTxnId'] ?></strong></div>
         <div class="col-md-3"></div>
      </div>
      
       <div class="row pt-4">
         <div class="col-md-3"></div>
         <div class="col-md-3"><strong>Transaction date :</strong></div>
           <div class="col-md-3"><strong><?= $jsonData['payInstrument']['merchDetails']['merchTxnDate'] ?></strong></div>
         <div class="col-md-3"></div>
      </div>
      
       <div class="row pt-4">
         <div class="col-md-3"></div>
           <div class="col-md-3"><strong>Bank transaction ID :</strong></div>
           <div class="col-md-3"><strong><?= $jsonData['payInstrument']['payModeSpecificData']['bankDetails']['bankTxnId'] ?></strong></div>
         <div class="col-md-3"></div>
      </div>
  
    </body>
</html>

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists