Reputation:
Upvotes: 5
Views: 1456
Reputation: 6463
If you are using PayPal Standard buttons, you can use Payment Data Transfer.
Just specify the return URL in return
parameter and PDT will return the transaction information. You will also need to enable Auto-Return in your PayPal account.
If you are using Express checkout, after the Doexpresscheckout is complete, you will get all the necessary information including transaction information in response. alternatively, call the GetTransactionDetails API to get the transaction information.
Also, if not in the return page, you can always use IPN to get the transaction details which is asynchronous. This is actually the recommended way to do any post-transaction processing you may need to do because it will allow you to correctly handle pending payments that may not clear for a few days.
Upvotes: 2