使用 Paypal 沙盒逐步创建结账表单 (PHP)

发布于 2024-09-26 03:30:40 字数 755 浏览 0 评论 0原文

大家好!

目前我正在处理我的学校项目。我需要使用 Paypal 创建一个结帐表单,并且该网站是用 php/apache/localhost 编写的。经过一番研究我知道我们可以使用Paypal Sandbox(不是真正的paypal)来模拟支付。但我不知道该怎么做。我读过一些教程,但只是让我变得更加困惑。我对 php-curl 的网络服务(soap)有一点了解。因此,如果有人曾经使用贝宝沙箱创建贝宝结账,您能否分享一下您使用最简单的术语和语言完成的步骤?

这是我能得到的最好的资源(但无法理解):

非常感谢,上帝保佑。


请注意,我可能是最懒的傻瓜(笑话

Good day, everyone!

Currently I'm working with my school project. I need to create a checkout form using Paypal and the website is written in php/apache/localhost. After a little research I know that we can use Paypal Sandbox (not the real paypal) to simulate payment. But I've no clue how to do it. I've read some tutorial, but just make me become more confuse. I know a little about web service (soap) with php-curl. So if anyone has ever create paypal checkout using paypal sandbox, could you share what step-by-step you've done using easiest term and language?

This are the best resource I can get (yet can't understand):

Thank you so much and God bless.


Note that I'm maybe the laziest dumb (joke)

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

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

发布评论

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

评论(1

向日葵 2024-10-03 03:30:40

试试这个代码。

  <form action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post" style="padding: 0; margin: 0;">
    <input type="hidden" name="cmd" value="_xclick/" />
    <input type="hidden" name="business" value="your bussiness id" />
    <input type="hidden" name="quantity" value="1" />
    <input type="hidden" name="item_name" value="your item" />
    <input type="hidden" name="item_number" value="1" />
    <input type="hidden" name="amount" value="item price" />
    <input type="hidden" name="shipping" value="0" />
    <input type="hidden" name="no_note" value="1" />
    <input type="hidden" name="notify_url" value="Your notify url">
    <input type="hidden" name="currency_code" value="GBP" />
    <input type="hidden" name="rm" value="2" >
    <input type="hidden" name="return" value="your return url">
    <input type="image" border="0" name="paypal" src="images/btn_paypal_nl.gif" onClick="" />
    </form>

谢谢,

康吉

Try this code.

  <form action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post" style="padding: 0; margin: 0;">
    <input type="hidden" name="cmd" value="_xclick/" />
    <input type="hidden" name="business" value="your bussiness id" />
    <input type="hidden" name="quantity" value="1" />
    <input type="hidden" name="item_name" value="your item" />
    <input type="hidden" name="item_number" value="1" />
    <input type="hidden" name="amount" value="item price" />
    <input type="hidden" name="shipping" value="0" />
    <input type="hidden" name="no_note" value="1" />
    <input type="hidden" name="notify_url" value="Your notify url">
    <input type="hidden" name="currency_code" value="GBP" />
    <input type="hidden" name="rm" value="2" >
    <input type="hidden" name="return" value="your return url">
    <input type="image" border="0" name="paypal" src="images/btn_paypal_nl.gif" onClick="" />
    </form>

Thanks,

Kanji

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