The main focus of this post is to share the steps to manually fix the WP user accounts and PMPro memberships for any user that had a successful payment at the PayPal gateway, but that membership wasn’t properly updated in their membership account in your WordPress site. Alternately, this guide explains how to create a user account if their payment was successful but the user was not created at checkout.
Recently there was an issue where random PayPal checkouts would fail. Payment would go through, PayPal would set up a subscription, but new users wouldn’t have their WP user account created and existing users would not have their membership changed. This specific issue was fixed in the v2.6.3 update, but similar things might happen for various other reasons.
If you are hearing reports like this from your customers or notice PMPro orders in “token” status while the related payments have been processed at PayPal, you should make sure your PMPro software is up to date, check for compatibility issues with any other plugin that hooks into user registration or the PMPro checkout, and finally open a ticket with us to help figure out what is happening and find a fix for your site.
How to Update a WP User Account’s Membership and Link an Order
Do this once:
- Activate the recipe in this guide so you can edit subscription transaction ids on orders: Make All Order Fields Editable in the Memberships > Orders Admin Page
Then for each user who had an issue at checkout:
- Manually create a user in WordPress if they didn’t already have one.
- Edit the user to assign their membership level to them. If the membership has an expiration, set that date. If the membership is recurring, set no expiration for the user.
- Log into PayPal and check if there are multiple payments on the PayPal side. If so, refund the older ones but keep the latest/most recent order. (Users might have retried checkout when it failed.)
- In PayPal, find the latest subscription for that user and note the Subscription ID. When viewing a single transaction, click the “View Recurring Payment Details” to see the subscription.
- Update the related order for this user that failed.
- Set the order’s Status to success.
- Set the User ID to the user’s ID.
- Set the Subscription Transaction ID to the one from PayPal. You don’t need to set the Payment Transaction ID, but you could find that and set it as well.
- (If you can’t find the order, you can also create it from scratch. Make sure the total, gateway, gateway environment, and other values are set as they would be on a new order.
We’d rather there not be issues like this. We’d rather you not have to do “manual” work to fix things when they go wrong. But if you have run into an issue like the one above, hopefully these steps help you to get things right on your membership site.
Author: Jason Coleman
Jason is co-founder of Paid Memberships Pro, the 100% open source membership plugin for WordPress. He has been pushing WordPress to its limits for many years and is an advocate for using WordPress as an application framework to build web sites and apps that go above and beyond the typical blog of CMS site.