<?php

   

$qryApi = mysqli_query($conn,"SELECT * FROM payment");
    
$apidata = mysqli_fetch_array($qryApi);


	
	
$getpaykey = $apidata['getpaykey'];    
$getpaysec = $apidata['getpaysec'];
$getpayurl = $apidata['getpayurl'];






$host = "https://$getpayurl/api/v1/sendmoney/?apikey=$getpaykey&accountNumber=$accno&bankCode=$variation&amount=$xamount&sender=$sender&referenceID=$requestId";





//Initialize cURL.

$ch = curl_init();

curl_setopt($ch, CURLOPT_URL, $host);

curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);


$dataR = curl_exec($ch);

$result = json_decode($dataR);


//Close the cURL handle.

curl_close($ch);



$resp = json_decode($dataR);



?>