2

我已经下载了 paypal mpl 并使用 phonegap 默认示例来测试沙箱。

我只是从示例中更改这些行

obj.paymentAmount = document.getElementById('pmt_subtotal').value;
obj.paymentCurrency = document.getElementById('pmt_currency').value;
obj.recipient = document.getElementById('pmt_recipient').value;
obj.merchantName = document.getElementById('pmt_merchant').value;
obj.itemDesc = document.getElementById('pmt_description').value;
obj.memo = document.getElementById('pmt_memo').value;
obj.tax = document.getElementById('pmt_tax').value;
obj.shipping = document.getElementById('pmt_shipping').value;

用这个静态值

var obj = {
        server : 'ENV_SANDBOX',
        appId : 'APP-80W284485P519543T'
    };
obj.paymentAmount = 10.0;
obj.paymentCurrency = 'USD';
obj.recipient = 'moin_k_1347963077_biz@yahoo.com';
obj.merchantName = 'Test Test';
obj.itemDesc = 'something';
obj.memo = 'something';
obj.tax = 0;
obj.shipping = 0;

当我点击 paypal pay 按钮时,它会引发错误

"The application is not approved to use the following parameters with this type of payment".

这是完整的 Eclipse 项目http://marinefreshbd.com/paypal/Paypal.zip

4

1 回答 1

1

对我来说,解决方案是更新了 mpl.java 文件,就像这个链接中所说的那样

https://groups.google.com/forum/#!msg/eclipse-plugin-for-phonegap/UnHBZ_u_TDM/Z8W432aGG4UJ

希望它可以帮助你。祝你好运。

奥雷里奥

于 2013-01-25T20:21:47.430 回答