【发布时间】:2016-11-18 03:40:23
【问题描述】:
我希望从我的 Wordpress/Woocommerce 自定义支付网关中的 process_payment 进行重定向。
要进行 GET 重定向,您可以:
function process_payment( $order_id ) {
//some code here
//CPN is a value entered by user from custom payment field
$cpn = $_POST['cpn'];
return array(
'result' => 'success',
'redirect' => 'https://www.sandbox.bankserver.com/cgi-bin/webscr?test_ipn=1&CPN='. $cpn
);
}
在自定义支付字段中从用户接收的值是安全敏感的,因此银行不希望通过 GET 接收它们。我怎样才能发帖?
我将 POST 到银行 URI...这将允许用户在银行页面上输入 CVV,然后重定向回我的 Wordpress 网站。
【问题讨论】:
标签: php wordpress woocommerce payment-gateway