我使用Express Checkout API(名称 - 值对)进行PayPal结账。问题是登录屏幕不显示订单摘要。我尝试将下面的参数设置为this post,但它仍显示空信息。
$options["PAYMENTREQUEST_0_DESC"] = "hieutot";
$options["PAYMENTREQUEST_0_ITEMAMT"] = "123";
$options["PAYMENTREQUEST_0_AMT"] = 300;
$options["PAYMENTREQUEST_0_PAYMENTACTION"] = "Sale";
$options["L_PAYMENTREQUEST_0_NAME0"] = "zzz";
$options["L_PAYMENTREQUEST_0_QTY0"] = 1;
$options["L_PAYMENTREQUEST_0_AMT0"] = 1000.00;
$options["L_PAYMENTREQUEST_0_NAME1"] = "test";
$options["L_PAYMENTREQUEST_0_QTY1"] = 1;
$options["L_PAYMENTREQUEST_0_AMT1"] = 200.00;
但是当我试图生成10486交易错误时。订单摘要出现!多么奇怪的问题!怎么解决?它可能是PayPal API错误吗?我正在使用Zend Cart 1.3.8。
这是使用cURL的请求和响应
REQUEST
Array
(
[ITEMAMT] => 0.00
[LOCALECODE] => US
[PAYMENTACTION] => Sale
[EMAIL] => sorryICannotShowThis@gmail.com
[PHONENUM] => xxxxxxxx
[SOLUTIONTYPE] => SOLE
[PAYMENTREQUEST_0_DESC] => hieutot
[PAYMENTREQUEST_0_ITEMAMT] => 123
[PAYMENTREQUEST_0_AMT] => 300
[PAYMENTREQUEST_0_PAYMENTACTION] => Sale
[L_PAYMENTREQUEST_0_NAME0] => zzz
[L_PAYMENTREQUEST_0_QTY0] => 1
[L_PAYMENTREQUEST_0_AMT0] => 1000
[L_PAYMENTREQUEST_0_NAME1] => test
[L_PAYMENTREQUEST_0_QTY1] => 1
[L_PAYMENTREQUEST_0_AMT1] => 200
[AMT] => 3,700.00
[RETURNURL] => https%3A%2F%2Flocalhost%2Fipn_main_handler.php%3Ftype%3Dec
[CANCELURL] => https%3A%2F%2Flocalhost%2Findex.php%3Fmain_page%3Dshopping_cart%26amp%3Bec_cancel%3D1
[PAGESTYLE] => Primary
[METHOD] => SetExpressCheckout
[CURRENCYCODE] => JPY
)
RESPONSE
Array
(
[TOKEN] => sorryICannotShowThis
[TIMESTAMP] => 2013%2d11%2d21T08%3a37%3a09Z
[CORRELATIONID] => 35adcd4bd76d5
[ACK] => Success
[VERSION] => 3%2e2
[BUILD] => 8549850
[CURL_ERRORS] =>
)
答案 0 :(得分:1)
请仔细检查API请求中使用的版本:
[VERSION] => 3%2E2
我建议使用63.0以上的任何版本(可以支持订单项)
“此字段在版本53.0中引入。自版本63.0以来,L_NAMEn已弃用。请改用L_PAYMENTREQUEST_0_NAME。”