【发布时间】:2013-05-18 15:29:17
【问题描述】:
我在我的网站上创建了一个订阅按钮,使用如下简单的形式。
<form name="mypaypalform" id="mypaypalform" action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="item_number" value="123">
<input type="hidden" name="cmd" value="_xclick-subscriptions">
<input type="hidden" name="no_note" value="1">
<input type="hidden" name="notify_url" value="http://dev2.pw/dev/payment-confirm/">
<input type="hidden" name="return" value="http://dev2.pw/dev/payment-confirm/">
<input type="hidden" name="business" value="leonard@kwikcost.com">
<input type="hidden" name="item_name" value="Subscribe to Expert"> <input type="hidden" name="src" value="1">
<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="srt" value="2">
<input type="hidden" name="bn" value="PP-SubscriptionsBF:btn_subscribeCC_LG.gif:NonHostedGuest">
<input type="submit" style="cursor:pointer;" class="centro_viewbuy" value="Subscribe us">
</form>
我已经在其中设置了 notify_url。它工作正常。当有人订阅我的网站时。它确实出现在我的通知页面,然后我将交易详细信息存储在我的数据库中。现在我的问题是当我的一些订阅者从他的贝宝帐户中按下“取消订阅”时。我需要以“取消”状态更新我的数据库。我怎么能这样做? 我不想使用 IPN 设置通知 URL。因为我将在我的许多网站上使用一个贝宝帐户。我希望贝宝在有人订阅时向我发送通知的同一页面上通知我。
提前致谢。
【问题讨论】:
标签: paypal payment subscription