Paypal IPN:如何捐赠至少 1 美元?

发布于 2024-08-28 13:55:39 字数 641 浏览 2 评论 0原文

目前,用户可以在 Paypal 网站上输入小于 1 美元的金额,并且由于 Paypal 费用,有些人的捐款结果为 0 美元。如何将最低金额设置为 1 美元或更多?

示例: https://www. paypal.com/us/cgi-bin/webscr?cmd=_flow&SESSION=SGbE2GfDX90hYuesj2R33WHFRQU02X3eGubWF2Yo7U37vTxrOFRjGtuQF7u&dispatch=50a222a57771920b6a3d7b606239e4d529b525 e0b7e69bf0224adecfb0124e9b5efedb82468478c6e115945fd0658595b0be0417afd2208f

Currently, the user can enter a quantity less than $1 on Paypal's website and some people are donations result in $0 because of Paypal fees. How can I set the minimum to be a $1 or more?

Example: https://www.paypal.com/us/cgi-bin/webscr?cmd=_flow&SESSION=SGbE2GfDX90hYuesj2R33WHFRQU02X3eGubWF2Yo7U37vTxrOFRjGtuQF7u&dispatch=50a222a57771920b6a3d7b606239e4d529b525e0b7e69bf0224adecfb0124e9b5efedb82468478c6e115945fd0658595b0be0417afd2208f

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

凌乱心跳 2024-09-04 13:55:39

在将其发送到 Paypal 之前,您可以使用表单验证来确保该值 >$1。
我会同时使用 Javascript 和 PHP 验证。 JavaScript 很好,因为处理是在客户端完成的,并且是在 http 请求之前完成的。需要 PHP 验证,因为客户端可以关闭 Javascript。

Javascript 验证的示例可能如下所示:

if(document.contact_form.amount.value <= 1)
{
  alert("Please enter in an amount greater or equal than $1");
  return false;
}

此外,请确保在显示“捐赠金额(最低 5 美元)”之类的字段旁边明确标记了“帮助者”文本。

You could use form validation to ensure the value is >$1 before sending it to Paypal.
I would use both Javascript and PHP validation. Javascript is nice because the processing is done on the client and is done before the http request. PHP validation is required because the client could turn off Javascript.

Example of Javascript validation could be something like this:

if(document.contact_form.amount.value <= 1)
{
  alert("Please enter in an amount greater or equal than $1");
  return false;
}

Also, make sure you have clearly labeled 'helper' text next to the field that says something like "Donation Amount (Minimum of $5)".

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文