Receive form only if Paypal payment is complete

≯℡__Kan透↙ 提交于 2019-12-26 03:47:02

问题


I'm looking for a way to receive a form result by email only if the payment has been completed on Paypal.

I have a form next to my shopping cart. I want people to fill the form, then they can browse in the shopping cart. Once they click on "Checkout" in the shopping cart, they are redirected on Paypal. The form I talked before is still on hold...not sent yet.

When the guy fills his credit card information, click Proceed on Paypal, and THEN... When the payment is complete, the form he filled on my website will be submited. But if he decide to close the paypal window and stop shopping, I won't receive it.

I need your help guys/girls. I'm not sure what language I need to make this work. I'm guessing PHP and Javascript.

Thanks a lot, This function is very important for us.


回答1:


Check out the IPN (Instant Payment Notification).

https://www.paypal.com/ipn/

It will send a message to your server after a payment has been made, sounds like what you are looking for. You can write the listener in PHP and they provide example code.



来源:https://stackoverflow.com/questions/11780964/receive-form-only-if-paypal-payment-is-complete

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!