WP Site Selling Users Digital Items After They Cancel the Order on Paypal
-
My WordPress site only has the Proceed to PayPal option when a user goes to checkout after adding digital items into their Woocommerce cart.
When they click this option and are taken to PayPal.com/webapps/hermes?token=XXX&useraction=commit&rm=2&wpsFlowRedirectToXorouterSkipHermesStartTime=XXX&flowType=WPS&mfid=XXX where there’s an option under the sign-in that says “Cancel and Return” to the site.
If the user signs in and pays, everything works and the payment goes through. However, if the user doesn’t sign-in to PayPal, doesn’t put their payment info in, then clicks that “Cancel and Return” option they are brought back to my website with this string added to the end of the URL?mysite.com/cart/?cancel_order=true&order=wc_order_XXX&order_id=XXX&redirect&_wpnonce=XXX
The problem is as soon as they return to my website after clicking the “Cancel” option the digital item is added to their account despite them not actually paying for it and the item still being in their cart.
When reviewing the transaction in Woocommerce’s logs it correctly shows the status of the order as Cancelled.
How can I ensure that the digital item is not added to the user’s account when the order is Cancelled or Pending?
- The topic ‘WP Site Selling Users Digital Items After They Cancel the Order on Paypal’ is closed to new replies.