In this post, we show you how to restrict posts or pages based on WP Ultimo sites count. This is useful to create premium content that only users with a certain number of posts will have access to.
Some of these premium content could be:
- Posts with tutorials
- Landing pages
- Course pages
- Event pages
- Posts with inspiration on the web design
- Posts with tips for site administration
- Etc.
Normally, you’d have to go through the tedious process of having to program the conditional restrictions from scratch by yourself, but you need plenty of programming knowledge.
Fortunately, we’ll show you how to easily do it using the WordPress Conditional Post Restrictions plugin. With this WordPress plugin, you can easily apply conditional restrictions to your posts, pages, products, courses, events, downloads, templates, files, recipes, forums, etc.
You can download the plugin here:
Download WordPress Conditional Post Restrictions Plugin - or - Read more
Once you install and activate the plugin, follow the steps in the sections below to learn how to restrict posts or pages based on sites count.
1- How to restrict individual posts based on the WP Ultimo sites count
First, we’ll show you how to easily restrict individual posts for users who have three sites. This is useful if you have just a few sites to restrict. It’s really simple because you just have to follow these simple steps:
- Go to Posts > All Posts in wp-admin.
- Open the post you want to restrict.
Now you need to scroll down to the Restriction rules section and select these values:
- Enable content restrictions: Yes
- What happens when the conditions are met: Allow access
- Condition 1: User sites count = 3
- Keep in mind that this number is just an example.
- Update the post to save the changes.
You’re done! Now, this post will be restricted for the users who have 3 plans. If you want to restrict other posts, just repeat the same steps in each post.
2- How to restrict categories based on the WP Ultimo sites count
Think of this situation:
- You don’t want to restrict individual posts because it’s so tedious.
- You don’t want to restrict all posts because there are some posts to which you want all users to have access.
We have the perfect solution. You can restrict categories based on the WP Ultimo sites count. Just follow these simple steps:
- Go to Posts > Categories in wp-admin.
- Open the category you want to restrict.
Now scroll down to the Post and Category restrictions section and select these values:
- Enable the conditional restrictions: Yes
- Apply restrictions to: Category and posts
- What happens when the conditions are met: Allow access
- Condition 1: User sites count = 3
- Keep in mind that this number is just an example.
- Update the category to save the changes.
Once you apply these changes, all the posts within the selected category will be blocked for users who don’t have the number of sites required by the conditional restriction. Repeat the same steps in other categories to restrict them as well.
3- How to restrict all posts based on the WP Ultimo sites count
This section explains the steps you need to follow in order to restrict all your WordPress posts based on the WP Ultimo sites count. We’ll show you how to restrict posts for users who have three sites in your multi-site network. Just follow these steps:
- Go to Settings > Post restrictions in wp-admin.
- Tick the Enable global restrictions checkbox.
- Click Add conditions to create a global condition.
Now you need to select these values in the new restriction:
- Add new restrictions: Enter the restriction title
- Select post types: Posts
- What happens when the conditions are met: Allow access
- Condition 1: User sites count = 3
- Keep in mind that this number is just an example.
- Publish the condition.
Once you publish this condition, all your WordPress posts will be restricted for all users who don’t have the number of sites your restriction states.
4- How to restrict individual pages based on the WP Ultimo sites count
You need to follow these simple steps if you want to restrict individual pages based on the WP Ultimo sites count:
- Go to Pages > All Pages in wp-admin.
- Open the page you want to edit with the normal WordPress editor.
Once you open the page you’ll restrict, select these values:
- Enable content restrictions: Yes
- What happens when the conditions are met: Allow access
- Condition 1: User sites count = 3
- Keep in mind that this number is just an example.
- Update the page to save the changes.
These steps are really simple, and allow you to restrict pages based on the sites count.
5- What if users try to access restricted content?
You can easily redirect all your users to an upgrade page when they try to access restricted content. Just follow these simple steps:
- Go to Settings > Post Restrictions in wp-admin.
Once there, you need to select these values:
- Don’t apply restrictions for these user roles: You’ll see a list of user roles for which the conditions won’t be applied. By default, we will not apply restrictions for administrators, editors, and any user with the capability edit_others_posts.
- What happens when the post is restricted? Redirect to URL
- Redirect to this URL: Enter the upgrade or pricing page.
- What happens when a category is restricted? Redirect to another URL
- Redirect to another URL: Enter the upgrade or pricing page.
- Save the changes.
After you apply these values, your users will be redirected to the selected URL every time they try to access blocked posts or pages.
You see? It’s really simple!
We told you it was really simple to restrict posts or pages based on the WP Ultimo sites count. Now you can freely create premium content and easily apply all the restrictions you want.
Remember that you can apply any conditional restriction to your posts, pages, courses, events, downloads, files, recipes, forums, etc. WordPress Conditional Post Restrictions makes it really easy!
You can download the plugin here:
Download WordPress Conditional Post Restrictions Plugin - or - Read more