Note: This is part of the developer docs and is considered custom code.
Unfortunately, we cannot provide support for custom code at this time as we do not have the additional resources that would be necessary to provide support for custom code.
If you need assistance with this, please reach out to our list of consultants for further assistance:
Restrict Content Pro includes a template file system that makes it really simple for users to customize the registration form, profile form, login form, and more. This quick tutorial will walk you through how to use them to make modifications to the default plugin display.
The template files reside inside of wp-content/plugins/restrict-content-pro/templates, and there is a template file for:
- The registration form - register.php, register-single.php, or register-single-xx.php (where xx is the subscription level ID number. Note: only works when supplying the ID number on the [register_form] shortcode. Example: [register_form id="2"] would load register-single-2.php if available.)
- The login form - login.php
- The profile editor form - profile-editor.php
- The change password form - change-password.php
- Lost password form - lostpassword.php and lostpassword_checkemail.php
- Card form - card-form.php
- Card form (full) - card-form-full.php
- Credit card update form - card-update-form.php
- Invoice form - invoice.php
- PayPal Express confirmation form - paypal-express-confirm.php
- Registration form totals section - register-total-details.php
- Subscription details - subscription.php
- Comments form - comments-no-access.php
- WooCommerce template override - WooCommerce-single-no-access.php
- Email design -
Any change you make to these files will be reflected in the display of the plugin, but in order to ensure that you can still update the plugin to the newest version without losing your changes, you need to copy the template files to a child theme ( https://developer.wordpress.org/themes/advanced-topics/child-themes/) and then modify them there. To copy the templates to an upgrade-safe location, do the following:
- Create a folder called rcp inside of your active theme's folder. If you're using the default Twenty Twelve theme, you should create a child theme, your new folder will look like this: wp-content/themes/twenty-twelve-child/rcp Note: If you are already using a child theme, just create the rcp folder in the child theme folder, and keep going!
- Copy the files from the Restrict Content Pro templates directory into the new folder created in your theme
- Modify the files to your heart's content
When modifying these template files, you do need to be careful and not remove any form fields or unique element IDs that Restrict Content Pro depends on. If you notice any problems with the plugin's behavior after modifying any of these templates, delete your modified file (after backing it up), then test again to see if the problem is resolved. If removing your modified file resolves the issue, work backward until you find the element you removed or changed that caused the problem. With the ability to modify template files, you have the freedom to set up the form markup exactly as you want, making it possible to create even the most beautiful membership forms. There is no limit.