Start a conversation

How do I integrate PayFast with Paid Memberships Pro?

This module was developed by Paid Memberships Pro, so please visit their website for integration support. You will need to be registered on PayFast to accept payments and get your merchant ID.

PayFast integration for v1.8.5

The Paid Memberships Pro plugin was developed by Stranger Studios. We simply forked their plugin (up to v1.8.5), adding the ability for visitors to pay for membership using South African rand with PayFast. If you have any questions about the functionality about Paid Memberships Pro, please get in touch with them. If you are having payment integration problems, get in touch with us. You will need to be registered on PayFast to accept payments and get your merchant ID. Register here. For integration with Paid Memberships Pro 1.8.6 please see the instructions below.

Paid Memberships Pro PayFast-fork integration (v1.8.5)

1. Download the ZIP file of the latest fork from https://github.com/PayFast/paid-memberships-pro

2. Upload it via the WordPress Dashboard or via FTP to the Plugins folder.

3. Activate the plugin.

4. Follow through the PMP documentation: http://www.paidmembershipspro.com/documentation/ (You’ll need to register for a free account to read all setup documentation.)

5. To configure PayFast, go to Memberships > Payment Settings. Enter your Merchant ID and Key.

Note: Whenever an update is available for the plugin and you update it from within WordPress (or from the developer’s site), it will update to their latest version (i.e. without PayFast payments). To ensure that the plugin stays PayFast-compatible, always download the latest version from our GitHub account. You’ll need to upload the updated files via FTP.

PayFast integration for v1.8.6 – 1.9*

v1.8.6 – 1.9*

1. Download the module and unzip the module to a temporary location on your computer.

2. Copy the ‘wp-content’ folder in the archive to your base WordPress folder. This will merge the folders in the PayFast module with your WordPress folders. You will be prompted to overwrite the paymentsettings.php file, select overwrite.

3. At this point it is necessary to add 2 lines of code to the paid-memberships-pro.php file which is in the root directory of the Paid Memberships Pro plugin. Open the file in a text editor and add the following lines of code:

Line 86 : require_once(PMPRO_DIR . '/classes/gateways/class.pmprogateway_payfast.php' );

Line 141 : 'payfast' => __('PayFast','pmpro'),

4. Log into the administration console of your website.

5. Select 'Memberships' from the menu, and go to 'Payment Settings'.

6. Under 'Payment Settings' select 'Payment Gateway and SSL'.

7. Choose 'PayFast' from the 'Payment Gateway' drop-down menu.

8. The PayFast options will then be shown below.

9. Leave everything else as per default and click 'Save Changes'.

10. The module is now ready to be tested in the PayFast sandbox (note: sandbox does not currently work for subscriptions).

11. When ready to go live input your PayFast Merchant ID and Key (and passphrase if it is set on your PayFast account) and click 'Save Changes'.

12. To setup a subscription, select ‘Recurring Subscription’. Currently Paid Memberships Pro can only accept monthly and annual subscriptions through PayFast

  • Note: If you have auto-renewal settings, this must be set to ‘No. All checkouts will setup recurring billing.’ It is not advisable to set an expiry date with the set expiry date plugin, rather set the cycles to the required number, or manage the subscription from the PayFast account dashboard.

13. Ensure that subscriptions are enabled on the Integration page (under Settings) on your PayFast account.

PayFast Add On

To install the PayFast payment module, follow the instructions below:

1. Make sure you have the Paid Memberships Pro plugin installed and activated.

2. Install the Add On via the Plugins > Add New in the WordPress dashboard. Or, upload the ‘pmpro-payfast’ directory to the ‘/wp-content/plugins/’ directory of your site.

3. Activate the plugin through the ‘Plugins’ menu in WordPress.

4. Navigate to Memberships > Payment Settings in your WordPress dashboard to complete the PayFast settings.

Choose files or drag and drop files
Helpful?
Yes
No