1<?
if (!defined(
"B_PROLOG_INCLUDED") || B_PROLOG_INCLUDED !==
true)
die();?><?
2if (
$_SERVER[
"REQUEST_METHOD"] ==
"POST")
6 $cs1 = intval($_POST[
"order_id"]);
8 $cs1 = intval($_POST[
"cs1"]);
11 if(!($arOrder = CSaleOrder::GetByID($cs1)))
14 $techMessage =
GetMessage(
"SALE_CHR_REC_ORDER");
18 CSalePaySystemAction::InitParamArrays($arOrder, $arOrder[
"ID"]);
31 $product_id = trim($_POST[
"product_id"]);
32 $customer_id = trim($_POST[
"customer_id"]);
33 $transaction_id = trim($_POST[
"transaction_id"]);
34 $transaction_type = trim($_POST[
"transaction_type"]);
35 $total = trim($_POST[
"total"]);
37 $date = trim($_POST[
"date"]);
38 $sign = trim($_POST[
"sign"]);
40 if($product_id == $productIdB)
42 $checkB = md5($sharedsecB.$customer_id.$transaction_id.$transaction_type.$total);
45 if($transaction_type ==
"onetime" || $transaction_type ==
"Purchase")
47 if($product_priceB == $total)
50 if($arOrder[
"PAYED"] !=
"Y")
51 CSaleOrder::PayOrder($arOrder[
"ID"],
"Y");
54 $techMessage =
GetMessage(
"SALE_CHR_REC_SUMM");
57 $techMessage =
GetMessage(
"SALE_CHR_REC_TRANS");
60 $techMessage =
GetMessage(
"SALE_CHR_REC_SIGN");
63 $techMessage =
GetMessage(
"SALE_CHR_REC_PRODUCT");
65 $strPS_STATUS_DESCRIPTION =
"Customer id: ".$customer_id.
";<br />";
66 $strPS_STATUS_DESCRIPTION .=
"Transaction id: ".$transaction_id.
";<br />";
67 $strPS_STATUS_DESCRIPTION .=
"Date payed: ".$date.
";<br />";
68 $strPS_STATUS_DESCRIPTION .=
"Payment type: ".$_POST[
"payment_type"].
";<br />".
69 "Buyer: ".$_POST[
"name"].
";<br />".
70 "Email: ".$_POST[
"email"].
";<br />".
71 "Country: ".$_POST[
"country"].
";<br />".
72 "City: ".$APPLICATION->ConvertCharset($_POST[
"city"],
"utf-8",
SITE_CHARSET).
";<br />".
73 "Street: ".$APPLICATION->ConvertCharset($_POST[
"street"],
"utf-8",
SITE_CHARSET).
";<br />".
74 "Phone: ".$_POST[
"phone"].
";<br />".
75 "Index: ".$_POST[
"zip"].
";<br />";
78 "PS_STATUS" => ($transaction_type ==
"onetime" || $transaction_type ==
"Purchase") ?
"Y" :
"N",
79 "PS_STATUS_CODE" => $transaction_type,
80 "PS_STATUS_DESCRIPTION" => $strPS_STATUS_DESCRIPTION,
81 "PS_STATUS_MESSAGE" => $techMessage,
84 "PS_RESPONSE_DATE" => Date(CDatabase::DateFormatToPHP(CLang::GetDateFormat(
"FULL", LANG))),
static GetParamValue($key, $defaultValue=null)
static Update($ID, $arFields, $bDateUpdate=true)
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
$_SERVER["DOCUMENT_ROOT"]
GetMessage($name, $aReplace=null)
GetLangFileName($before, $after, $lang=false)