Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Snickser committed May 17, 2024
1 parent 7aff948 commit 7391f4b
Showing 1 changed file with 18 additions and 19 deletions.
37 changes: 18 additions & 19 deletions pay.php
Original file line number Diff line number Diff line change
Expand Up @@ -157,29 +157,28 @@
$DB->update_record('paygw_payeer', $paygwdata);

// Make payment request.
$murl = 'https://payeer.com/merchant/';
$mshop = $config->shopid;
$morderid = $paymentid;
$mamount = number_format($cost, 2, '.', '');
$mcurr = $currency == 'RUR' ? 'RUB' : $currency;
$mdesc = base64_encode($description);
$mkey = $config->apikey;
$url = 'https://payeer.com/merchant/';
$shop = $config->shopid;
$amount = number_format($cost, 2, '.', '');
$currency = $currency == 'RUR' ? 'RUB' : $currency;
$desc = base64_encode($description);
$key = $config->apikey;

$arhash = [
$mshop,
$morderid,
$mamount,
$mcurr,
$mdesc,
$mkey,
$shop,
$paymentid,
$amount,
$currency,
$desc,
$key,
];
$sign = strtoupper(hash('sha256', implode(":", $arhash)));

redirect($murl . "?
mshop={$mshop}&
morderid={$morderid}&
mamount={$mamount}&
mcurr={$mcurr}&
mdesc={$mdesc}&
redirect($url . "?
m_shop={$shop}&
m_orderid={$paymentid}&
m_amount={$amount}&
m_curr={$currency}&
m_desc={$desc}&
m_sign={$sign}
");

0 comments on commit 7391f4b

Please sign in to comment.