following up on this question, I now have another problem – how can I delete the cart session if the buyer didn’t click the return link after payment?
I only can delete the cart session when the buyer click the return link, but what if they come straight to my shopping site without clicking the return?
This is similar to this question that was raised before by chris. And the answer seems to be,
You’ll have to clear the session variables on the return to your site
after successful payment. It’s not foolproof – there are possibilities
that the cart still won’t be cleared, but this is pretty much the only
way to do it.
But I still wonder if there are any solutions or is this the shortcoming in integrating with paypal that I have to accept? What about other gateways like Authorize.net?
This won’t happen with Authorize.Net as none of the payment APIs are dependent on the customer clicking on a link after payment (or doing anything after payment). Their SIM API uses Relay Response after the payment is made and since that page is called from your website you can clear the session with 100% certainty every time. Their Advanced Integration Method (AIM) and Direct Post Method (DPM) have the customer finishing the checkout process on your website so you also have full control over their session.