如何将网站中的用户名链接到 PayPal 信息电子邮件?
这不是问题,但我不知道该怎么做;假设我有一个注册表单,其中包含一些字段:用户名、密码、电子邮件,正如您所知,用户点击“购买”按钮并付款。
好吧,我怎么知道刚刚付款的用户名,我的意思是如何将这两件事链接在一起,一种想法是使用电子邮件地址,但大多数人使用不同的电子邮件地址注册,也许他们有一个不同的贝宝地址...你知道...我需要这些信息,因为我需要一种激活帐户的方法。
我还需要知道,如果用户取消订阅,PayPal 是否会向我的 IPN 链接发布消息?
It's not a problem but i don't know how to do this; let's say that I have a sign up form with some fields: username, password, email, as you know the user clicks on the BUY BUTTON and pay's up.
Well, how can I know the username that just made the payment, I mean how can I link those two things together, one idea it's to use the email address, but mose of the people sign up with different email addresses, mabe they have a different paypal address...you know...I need this information because I need a way to activate the account.
And I also need to know, if the user canceled a subscription will paypal post a message to my IPN link?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
我建议您使用以下 PHP 脚本来轻松与 PayPal 服务集成(假设您使用的是 PHP): http://www.micahcarrick.com/04-19-2005/php-paypal-ipn-integration-class.html
如果您这样做,e - 将提供您要查找的邮件
(再次假设
$paypal
是您的 paypal_class 类的对象)显然您必须首先遵循设置步骤。我建议使用示例脚本。这真的很容易做到——只需四个步骤。
I suggest you use the following PHP script for easy integration with PayPal's service (assuming you're using PHP): http://www.micahcarrick.com/04-19-2005/php-paypal-ipn-integration-class.html
If you do, the e-mail you will be looking for will be supplied in
(again, assuming that
$paypal
is your object of the paypal_class class)Obviously you have to follow the setup steps first. I suggest using the example script. It is really easy to do - in only four steps.
我建议您阅读有关 IPN 和定期付款的 PayPal 官方文档。
PayPal 为用户订阅发生的每个事件发出 IPN,例如:
subscr_signup
子脚本_eot
取消订阅
subscr_failed
关于该参数,您可以使用名为“custom”的参数来传递一个值,例如用户 ID 或电子邮件,该参数将在每个 IPN 中发送给您。
I suggest you read the official paypal documentation about IPN and recurring payments.
PayPal issues a IPN for every event that occurs to the user subscription, for example:
subscr_signup
subscr_eot
subscr_cancel
subscr_failed
About the parameter, you can use a parameter named "custom" to pass a value, for example the user id or email, and that parameter will be sent you in every IPN.
以下是 PayPal IPN 在 C# 和 VB 中的实现:
http://www.xdevsoftware.com/PPIPNDesc .aspx
以下是我如何将其合并到 PayPal 订阅方案中的说明:
http://www.codersbarn.com/post/2008/07/10/ASPNET-PayPal-Subscriptions-IPN.aspx
Here are implementations of the PayPal IPN in both C# and VB:
http://www.xdevsoftware.com/PPIPNDesc.aspx
Here's an account of how I incorporated it into a PayPal subscriptions scenario:
http://www.codersbarn.com/post/2008/07/10/ASPNET-PayPal-Subscriptions-IPN.aspx