0

我试图让 PayPal 的链式支付在他们的沙箱环境中工作。但是每当我在登录后的最后一个阶段点击“支付”时,我总是会被重定向到一个带有一般错误消息的页面“您的支付无法完成。请返回参与的网站并重试。”

我尝试过以相同的结果进行链式支付和并行支付。我还遵循了网络上的一些建议,这些建议调整了商家帐户设置,确保在“阻止”选项下未选中某些字段。以及检查货币和国家代码。最初的国家代码是 en_GB 和货币 GBP,这不起作用我尝试用美元做 en_US 但在所有情况下我都得到相同的消息。

我还尝试添加一个 IPN 网址,以防 PayPal 向其发布一些错误代码/消息,但得到了 nadda!如果您单击“返回测试商店”,它将转到取消 URL,而没有任何 POST/GET 参数。

我正在使用来自http://paypal.github.io/#adaptive-payments-tab-php-5-3的 PHP SDK

错误页面截图

可能是来自贝宝错误页面的相关信息的屏幕截图

所以问题是,有人对我如何找出究竟出了什么问题或我可以尝试解决的其他问题有任何建议吗?

4

2 回答 2

0

我在沙盒环境中遇到了这个问题,因为我没有包含应用程序 ID。我使用APP-80W284485P519543T了指示为沙盒应用程序 ID 的示例之一然后它起作用了。

于 2013-08-20T18:35:38.867 回答
0
    Mobile Payments Library Developer Guide and Reference 
    –
    Android OS
Edition
Oct 2016
5
Preface
**Important:
The Mobile Payments Library is based on the PayPal Adaptive Payments API. 
As of October 6, 2016, Adaptive Payments is now a limited releas
e product. It is restricted to 
select partners for approved use cases and should not be used for new integrations without guidance from PayPal**  

     =============================================

      first implement method
           private void initLibrary() {
                PayPal pp = PayPal.getInstance();
                if(pp == null) {
                    pp = PayPal.initWithAppID(this, PAYPAL_APP_ID, PayPal.ENV_SANDBOX);
                    pp.setLanguage("en_US"); // Sets the language for the library.
                    pp.setFeesPayer(PayPal.FEEPAYER_EACHRECEIVER);
        //            pp.setShippingEnabled(true);
                    pp.setDynamicAmountCalculationEnabled(false);
                }
            }    


        **paypal button click event code**

             double secondary_payment = 0;
            double primary_payment = 0;

              PayPalAdvancedPayment advPayment = makeChainedPayment(secondary_payment,primary_payment,"primary_email","secondary_email");

              Intent checkoutIntent = PayPal.getInstance().checkout(advPayment, your_current_activity);
                            startActivityForResult(checkoutIntent, 1); 

            =============================================
            private PayPalAdvancedPayment makeChainedPayment(double priceSecondary, double pricePrimary, String primary_email, String secondary_email) {
                    PayPalAdvancedPayment payment = new PayPalAdvancedPayment();
                    payment.setCurrencyType("USD");
            //        payment.setMerchantName("PushND");
                    BigDecimal bigDecimalPrimary=new BigDecimal(pricePrimary);
                    PayPalReceiverDetails receiverPrimary = new PayPalReceiverDetails();
                    receiverPrimary.setRecipient(primary_email);
                    //receiverPrimary.setRecipient("adaptive_receiver_1@pushnd.com");
                    receiverPrimary.setSubtotal(bigDecimalPrimary);
                    receiverPrimary.setIsPrimary(true);
                    payment.getReceivers().add(receiverPrimary);

                    PayPalReceiverDetails receiverSecondary= new PayPalReceiverDetails();
                    receiverSecondary.setRecipient(secondary_email);
                    BigDecimal bigDecimalSecond=new BigDecimal(priceSecondary);
                    receiverSecondary.setSubtotal(bigDecimalSecond);
                    payment.getReceivers().add(receiverSecondary);

                    return payment;
                }
于 2016-05-27T06:17:34.437 回答