gpt4 book ai didi

post - 成功页面上的 Paypal 返回变量

转载 作者:太空宇宙 更新时间:2023-11-03 16:02:11 25 4
gpt4 key购买 nike

我想做什么我只是想显示 Paypal 订阅注册的结果。我发现无法看到 POST 变量的问题是一个常见问题。

我尝试了很多不同的方法来做到这一点,我发现一个常见的解决方案是使用:

<input id="rm" name="rm" type="hidden" value="2">

这行不通。

我尝试给自己发送电子邮件 $_POST 和 $_REQUEST 变量,但它们是空的。

但是,我检测 txn_type $_POST 变量的代码有效,因为我的变量出现在我的数据库中。写入数据库后,它应该显示收据,但没有。

这是按钮代码:

<form action="https://www.paypal.com/cgi-bin/webscr" method="post">

<!-- Identify your business so that you can collect the payments. -->
<input type="hidden" name="business" value="paypalemail@gmail.com">

<!-- Specify a Subscribe button. -->
<input type="hidden" name="cmd" value="_xclick-subscriptions">
<!-- Identify the subscription. -->
<input type="hidden" name="item_name" value="Monthly Featured Listings">
<input type="hidden" name="item_number" value="1">

<!-- Set the terms of the regular subscription. -->
<input type="hidden" name="currency_code" value="USD">
<input type="hidden" name="a3" value="0.01">
<input type="hidden" name="p3" value="1">
<input type="hidden" name="t3" value="M">
<input type="hidden" name="rm" value="2">

<!-- Set recurring payments until canceled. -->
<input type="hidden" name="src" value="1">
<input name="notify_url" value="http://www.example.com/user/register/index.php" type="hidden">
<input name="return" value="http://www.example.com/user/register/index.php" type="hidden">
<input name="cancel_return" value="http://www.example.com/user/register/index.php?payment=cancelled" type="hidden">
<!-- Display the payment button. -->
<input type="image" name="submit" border="0" src="http://www.example.com/images/register-and-pay-now.png" alt="PayPal - The safer, easier way to pay online">
<img alt="" border="0" width="1" height="1" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif">

由于我的数据库代码有效,我只能猜测 Paypal 正在正确发送信息,但我无法让它显示在网页中。

我的问题重定向后如何在我的页面中显示成功的 $_POST 变量?

最佳答案

好吧,我的猜测是您接收并存储到数据库的变量正在访问 notify_url

这些变量是 IPN 变量,不应显示在任何网页上。

为了获得有关指定 return URL 的信息,您必须访问 PDT 数据。阅读更多关于 PDT 的信息 here

关于post - 成功页面上的 Paypal 返回变量,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22081537/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com