无法向 paypal 发送价值
PayPal IPN 直接向您的脚本发送通知。由于通知来自 PayPal - 不是下订单的客户 - 我的登录会话不会退出此上下文。因此,会话中不存在我的所有登录数据。我需要我的登录会话值来更新我的数据库与 paypal ipn 值。我应该如何维护我的登录会话,如果我设置浏览器会话或其他方式可以将登录主密钥发送到 paypal。
PayPal IPN sends a notification to your script directly. Since the notification is coming from PayPal - NOT the customer that placed the order - My Login session doesn't exits this context .Therefore,all my login data doesn't exist in the session.I need my login session values to update my DB with paypal ipn value.How should i mentain my login session should i set browser session or other way can i send login primary key to paypal.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在将您的客户发送到 PayPal 之前,您也许应该使用您自己唯一的订单 ID 将临时订单(客户信息和商品)保存到数据库中。
然后,您将订单 ID 作为发票变量发送到 Paypal,稍后您将从 IPN(回调)收到该 ID。
从 IPN 中,您可以获得交易所需的所有信息,然后您还可以根据自己的临时数据库检查这些信息。
Before sending your costumer to PayPal you should perhaps save a temporary order(client info and items) into db with your own unique order id.
The order id you then send as invoice variable to Paypal which you later will receive from the IPN (callback).
From the IPN you get all the information you need on the transaction which you then also can check against your own temporary db.