RecordMyLog("支付银行:" . $banks); RecordMyLog("送货信息:" . $contractName); RecordMyLog("发票抬头:" . $invoiceTitle); RecordMyLog("支付人:" . $mobile); RecordMyLog("支付时间:" . $payDate); RecordMyLog("保留字段:" . $reserved); RecordMyLog("支付结果:" . $status); } die("SUCCESS"); } if ($newhmac == $hmac) { $currency = 'CNY'; $service = 'cmpay'; $bank = '手机支付'; ZOrder::OnlineIt($order_id, $orderId, $v_amount, $currency, $service, $bank); // 记录日志 RecordMyLog("流水号:" . $payNo); RecordMyLog("支付金额:" . $amount); RecordMyLog("金额明细:" . $amtItem); RecordMyLog("支付银行:" . $banks); RecordMyLog("送货信息:" . $contractName); RecordMyLog("发票抬头:" . $invoiceTitle); RecordMyLog("支付人:" . $mobile); RecordMyLog("支付时间:" . $payDate); RecordMyLog("保留字段:" . $reserved); RecordMyLog("支付结果:" . $status); die('SUCCESS'); } else { RecordMyLog("验签失败!"); die('验签失败!'); }
$invoiceTitle = $_REQUEST["invoiceTitle"]; $invoiceTitle = decodeUtf8($invoiceTitle); $mobile = $_REQUEST["mobile"]; $orderId = $_REQUEST["orderId"]; $payDate = $_REQUEST["payDate"]; $reserved = $_REQUEST["reserved"]; $reserved = decodeUtf8($reserved); $status = $_REQUEST["status"]; $amtItem = $_REQUEST["amtItem"]; $signData = $merchantId . $payNo . $requestId . $returnCode . $message . $sigTyp . $type . $version . $amount . $banks . $contractName . $invoiceTitle . $mobile . $orderId . $payDate . $reserved . $status; //if($version == "1.0.1") $signData = $merchantId . $payNo . $requestId . $returnCode . $message . $sigTyp . $type . $version . $amount . $banks . $contractName . $invoiceTitle . $mobile . $orderId . $payDate . $reserved . $status . $amtItem; $hash = hmac("", $signData); $newhmac = hmac($signKey, $hash); RecordLog("YGM", "###backurl" . $hmac . "backurl###"); RecordMyLog("*backurl*" . $hmac . "*backurl*"); @(list($_, $order_id, $city_id, $_) = explode('-', $orderId, 4)); $v_amount = $amount / 100; //print_r($v_amount); //exit; if ($_ == 'charge') { if ($newhmac == $hmac) { $pay = Table::Fetch('pay', $orderId); } if ($pay) { Session::Set('notice', "手机支付充值{$v_amount}元成功!"); } /* @list($_, $user_id, $create_time, $_) = explode('-', $orderId, 4); if(ZFlow::CreateFromCharge($v_amount, $user_id, $create_time, 'cmpay')){ Session::Set('notice', "手机支付充值{$v_amount}元成功!"); }