Paypal支付跳转失败的原因及解决办法

遇到在跳转到paypal支付页面的时候出现502 bad gateway的错误,跳转的URL是
https://www.paypal.com/cgi-bin/webscr?locale.x=zh_HK

换了个paypal button id就可以,或者随便填个不存在的buttion id,也行。所以初步怀疑是paypal button的问题。登录paypal.com进入查看Tools->All tools->Paypal buttons
选择有问题的button,create simile button,创建一个一样的button,删除drop menu 下的选项。然后先增加一项,输入内容和价格(是中文的内容)。获取form 代码,放在html中运行,可以跳转。再逐个增加,当增加到第六个时,出现了502错误,删除掉第六个又没问题

是不是第六项的内容有什么特殊字符?没发现。

然后将所有dropmenu的内容都改成英文,增加到8项。没问题

是不是对中文支持不好,如果不好,增加到5项又没问题哦。所以是不是长度限制了?

再将每项的内容整理下,在保持意思的前提下,缩减内容。填写了8项内容和价格

重新生成html,可以跳转成功。

因此,这个问题是paypal对drop menu的长度处理有限制,但是又没提示。更重要的是,之前没问题,现在突然发现有这个问题,也不知道什么时候出现这个问题。paypal真的好渣啊

找到paypal的官方说明:

Using Options Fields on Your Website


Option fields let your customers specify options (such as size or colour) for the items they purchase. Each item may have up to two options, and option fields are compatible with Buy Now Buttons, PayPal Shopping Cart, and Subscriptions and Recurring Payments buttons.

The requirements for your options fields are:
Each option name is limited to 30 characters
Your drop-down menu choices should not exceed 10 menu items of 30 characters each (if you are using the Button Factory to generate your HTML code. If you are editing the code by hand, you may add additional menu choices)
Option fields cannot be used for options that will alter the item's price
You will need to be comfortable editing HTML code to perform some of the tasks outlined in this article.

https://www.paypal.com/uk/cgi-bin/webscr?cmd=p/xcl/rec/options-help-outside
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值