Membership sites allow people to register and log-in to gain privileges. Some membership sites offer access to restricted content. Others allow members to post and edit their content. Some allow members to communicate between themselves.
In this tutorial, we’ll teach how to build a membership site with Toolset. Your site will include the “user account” area, which allows members to log-in. You will learn how to create content that only members can access and how to build forms that allow members to edit their details.
We will use the following Toolset components for this tutorial:
- Access – to set-up custom user roles and control what different kinds of users can do
- Forms – to create the forms that allow members to register, edit their details and create content
- Types – to set-up custom post types, which will be the “user generated content” on the site
- Views – to build all the front-end display on the site
If you are planning to charge payment for registering to your site, you’ll also need:
- WooCommerce – to implement the entire payment processing and reporting
- Forms Commerce – to allow to charge payment when registering
Access plugin lets you create the custom roles for members and assign the correct privileges to them.
- Go to the Toolset -> Access Control and click the Custom Roles tab.
- Use the Add new role button to add the roles that you need. You can add as many custom roles as you like.
As a starting point, you can copy the default privileges from the Subscriber role. Of course, you can go ahead and set your own privileges for each role.
* Toolset saves custom roles the same way as WordPress saves the built-in roles. This means that other plugins will see your custom roles.
Access plugin also lets you choose what actions different users (by their roles) can do and what content they can access. Let’s go through the different ways you can control access to the site’s content.
The most efficient way to restrict read access to some of your content is to separate it as a Custom Post Type (CPT) and exclude read access to this CPT for visitors
Sometimes you may need to restrict access to certain pages and not to the entire post type. You can do this using the post groups feature of the Toolset Access plugin.
Certain parts of your posts may include information you would like to show only to members with special privileges. You can do this using the conditionally-displayed text feature of the Toolset Access plugin.
We would like to provide video courses for VIP and Premium members on our membership site.
Often membership sites provide some files to download.
Some membership sites allow the members to sign up for different activities that are exclusively for members.
In our example, we want to give the VIP members the possibility to sign up for webinars.
Your membership site needs to offer visitors to register (create WordPress accounts). Then, they need to log-in and they need to change account preferences. Let’s see how Toolset lets you create all these using front-end forms.
Toolset Forms plugin will let you create forms for front-end user registration and editing. You can create separate forms for different kinds of users, so that forms will contain the exact fields that each kind of user has.
Once your forms are ready, you can link to them from one page where users can choose their membership plans.
Check the following Forms tutorials for details:
To allow users to login to your site, create a custom login form that fits the overall look of your site.
You can build custom login forms and pages using the Toolset Views plugin.
After the user logs in, display links to the user’s resources.
Check the following tutorials for details:
If you decide to create a custom login page, it’s good to build a custom “Lost password” page as well. See the picture.
Toolset Views provides two shortcodes that help you create custom “Lost password” and “Reset password” pages.
Check this part of the “My account page” tutorial for details.
For charging fees for registration, use the WooCommerce plugin. Toolset integrates well with WooCommerce and allows you to connect a user registration form with a WooCommerce product.
In our example, the VIP membership is a time unlimited subscription, which means that it will never expire and the user pays only once, when creating a user account.
For one-time payments, simply connect your Toolset form for registering users with a WooCommerce product. Every time users want to register, they will need to pay the amount set by the product.
You will need to use the following plugins to charge payment for registration:
- Toolset Forms – included in Toolset package
- Toolset Forms Commerce – included in Toolset package
- WooCommerce – free
Now, create a “virtual product” with WooCommerce and set its price to what you want to charge for registration. Then, you connect the product with the user form you created to register your VIP members.
See the Charging payments with Forms to register users tutorial for details.
For handling recurring payments (time-limited subscriptions and those that can be renewed after a specific period), you will need the WooCommerce Subscriptions add-on.
- In WooCommerce Subscription settings, define how the role will change if the subscription expires.
- Create a WooCommerce Product.
- Change the product type to Subscription.
- Set the price and renewal period.
After filling in all the WooCommerce fields on the checkout page a new user account will be created with the Customer role (a WooCommerce role). Once the customer order is marked as completed, the user role will automatically change to the role you had chosen in the Subscriber Default Role.
See How to use the WooCommerce Subscriptions plugin with Toolset for step-by-step instructions.
thank you for reading the tutorial, I really appreciate it.