How it Works
This Add On is inspired by sites like the New York Times, which limits users to 5-10 monthly article views before redirecting users to a paywall.
This plugin sets a cookie for each visitor to track their views. The plugin’s settings page allows you to set the number of visits per “term” for non-members as well as for each membership level. It will allow visitors or members limited access to view posts they do not already have access to view. Once the user’s view limit is reached, they are redirected to the assigned page (most people select the Membership Levels page).
- PMPro Plus members can install the add on via the Memberships > Add Ons admin page.
- Or, download the plugin file and upload the ‘pmpro-limit-post-views’ directory to the ‘/wp-content/plugins/’ directory of your site.
- Activate the plugin through the ‘Plugins’ menu in WordPress.
- Navigate to Memberships > Limit Post Views
- From this page, you can configure the viewing limits for non-members as well as for each membership level.
- You can also set the “term” for viewing limits (per hour, day, week, or month).
- Assign a membership level to the post or category.
- Set the page to redirect users to once the viewing limit is reached.
Great for SEO
This add on is also a great workaround to allow search engines “in” to index your content.
If you set post views to 1, search bots can access posts and index them. We’re working on other unique code to allow search bots to scan your full site for SEO, but until that time this is the interim solution.
Action and Filter Hooks
The following filters are available in this Add On:
apply_filters( 'pmprolpv_has_membership_access', bool true, array $queried_object );
apply_filters( 'pmprolpv_post_types', array $post_types );