【问题标题】:Pay Pal IPN Notification not working in sandbox accountPaypal IPN 通知在沙盒帐户中不起作用
【发布时间】:2013-06-26 00:19:37
【问题描述】:

我正在使用贝宝沙盒帐户,我有立即购买按钮。 我的表格在这里:index.php

<form action="https://www.sandbox.paypal.com/cgi-bin/webscr" method="post">
     <input type="hidden" name="cmd" value="_xclick">
<input type="hidden" name="business" value="xxxxxx@gmail.com">
<input type="hidden" name="return" value="http://xxxx.net/success.php">
<input type="hidden" name="cancel_return" value="http://xxxxx.net/cancel.php">
<input type="hidden" name="notify_url" value="http://xxx.net/ipn.php">
<input type="hidden" name="currency_code" value="USD">
<input type="hidden" name="item_name" value="Bike">
<input type="hidden" name="amount" value="12.99">
<input type="hidden" name="a3" value="5.00">
<input type="hidden" name="p3" value="1">
<input type="hidden" name="t3" value="M">
<input type="hidden" name="rm" value="2">
<input type="hidden" name="invoice" value="ADDEdEd3dd3">
<input type="image" src="https://www.sandbox.paypal.com/en_US/i/btn/btn_buynow_SM.gif" border="0" name="submit" alt="Make payments with PayPal - it's fast, free and secure!">
</form>

这是我的成功.php

<?php
$con = mysql_connect("host","user","pass");
mysql_select_db("db");
if($con == null) {
        echo "Not any connection..";
} else {
        $re = mysql_query("insert into test(value) values('inserted')");
        if($re != 0) {
             echo "Data inserted..";
        } else {
             echo "Error while adding data..";
        }
}
?>

我启用了 IPN 通知设置和 url,我还启用了自动重定向 url,一切正常。但 IPN 通知不起作用。

任何想法,我只是想 ping 这个页面。

【问题讨论】:

    标签: php paypal paypal-sandbox paypal-ipn


    【解决方案1】:

    在这里https://developer.paypal.com/webapps/developer/applications/ipn_simulator尝试IPN模拟器,看看它是否可以发送IPN消息。如果失败 - 它会告诉你原因。

    【讨论】:

      猜你喜欢
      • 2012-04-09
      • 2016-10-02
      • 2015-11-25
      • 2013-05-19
      • 2015-09-27
      • 2015-11-25
      • 2020-02-16
      • 2012-06-25
      • 2011-11-01
      相关资源
      最近更新 更多