Mini Shell
<?php
$merchant_id = $_POST['merchant_id'];
$order_id = $_POST['order_id'];
$payhere_amount = $_POST['payhere_amount'];
$payhere_currency = $_POST['payhere_currency'];
$status_code = $_POST['status_code'];
$md5sig = $_POST['md5sig'];
$merchant_secret = 'f83b4576f51a2dc93eb2a8b11e01671b'; // Replace with your Merchant Secret (Can be found on your PayHere account's Settings page)
//$local_md5sig = strtoupper (md5 ( $merchant_id . $order_id . $payhere_amount . $payhere_currency . $status_code . strtoupper(md5($merchant_secret)) ) );
//$updatePayment = mysqli_query($connt, "INSERT INTO payments (`txnid`, `payment_amount`, `payment_status`) VALUES ('".$order_id."', '".$payhere_amount."', 'Success')");
/*
if (($local_md5sig === $md5sig) AND ($status_code == 2) ){
$updatePayment = mysqli_query($connt, "INSERT INTO payments (`txnid`, `payment_amount`, `payment_status`) VALUES ('".$order_id."', '".$payhere_amount."', 'Success')");
}
*/
?>
Zerion Mini Shell 1.0