GET FREE VERSION GET THE PRO VERSION

WooCommerce Memberships

Learn about integration with WooCommerce Memberships plugin - products and taxonomies restrictions, advanced search results filters based on user membership.

In this article

Overview

Key features of integration:
  • Respect all restriction rules. View/purchase will be allowed only for relevant members.
  • New search results filters. Set of search results filters based on parameters of WooCommerce Memberships plugin.
  • Users search and filters. Search for users and filter them depending on their membership plan.

WooCommerce Memberships is an advanced membership plugin. It gives the option to build complex membership sites with different plans, content access restriction and memberships selling.

We are happy to say that Advanced Woo Search plugin is fully integrated with WooCommerce Memberships. Even more - it has some advanced features like search results filters based on user membership or users search. We will cover all these features in the following sections.

How to restrict content with WooCommerce Memberships plugin

One of the features of WooCommerce Memberships plugin is the option to restrict products/taxonomies. It is possible to make such content available only for certain users that have appropriate membership.

In this section we will cover how to restrict access to certain products and products categories.

Steps to create new membership and restrict content:

1. Install and activate WooCommerce Memberships plugin.

2. Go to WooCommerce -> Memberships -> Membership Plans. Click Add Membership Plan to create your first membership plan.

3. On the next page you need to specify details of new membership. Add its name, slug. On the Restrict Products tab choose products and categories that must be restricted for the users that are not members of this specific plan.

Membership plan details

Membership plan details

Take a look on Only members can option - here you can set restriction type - view or purchase. You can hide products/categories content from users or just forbid them from buying those products.

When you are done with all options - click Publish button to create and activate a new membership plan.

4. Now we need to assign this new membership plan to specific users. Go to WooCommerce -> Memberships -> Members page. Click Add Member button. Inside the pop-up you can assign an already existing user or a new one to the previously created membership plan. Choose any user that you need.

Assign users to a membership plan

Assign users to a membership plan

5. (optional) Go to WooCommerce -> Settings -> Memberships page. Change any options here on your choice. Take a look on Content restriction mode option - if previously you choose restriction type view for products - then here you can choose how to restrict such products - fully hide them or only hide products content.

WooCommerce Memberships plugin settings

WooCommerce Memberships plugin settings

6. We're done! Your store content should now be restricted according to the membership plan parameters you set.

Product is restricted for current user

Product is restricted for current user

Content restriction for search results

Advanced Woo Search plugin respects all restrictions that are set for products and products categories via WooCommerce Memberships.

You don't need to make any extra steps here - once the restrictions are set for specific users - search results won't show these products to users that don't have access to them. Same works and for product categories.

Restricted product inside search results

Restricted product inside search results

If you set Content restriction mode option to Hide completely then you want to see that restricted product inside search results at all.

'Content restriction mode' option

'Content restriction mode' option

Restricted product is hidden from search results

Restricted product is hidden from search results

If, when setting up membership plan details, you restrict only product purchase then in the search results that restricted product will be displayed without Add To Cart button ( available only for PRO plugin version ).

Product purchase restriction

Product purchase restriction

Search results with products that are restricted to purchase

Search results with products that are restricted to purchase

Search results filters

Advanced integration with WooCommerce Memberships plugin gives an option to use a bunch of new search results filters.

With these new filters you can filter search results based on the current user membership plan. Or hide/show only restricted products/categories. Or show in search results only users with specific membership plans. Or you combine all these filters together to create complex filtering logic.

Below we will shortly cover all these new search results filters.

Products filter: Is product restricted for current user

Hide/show products that are restricted for current shop user.

To set such a filter open the plugin settings page -> Search Results tab and find Filter Results section. Click on Filter products search results button and then choose Woo Memberships: Is product restricted for user rule. Set compare operator and value ( Yes or No ) depending on your needs.

'Woo Memberships: Is product restricted for user' products results filter

'Woo Memberships: Is product restricted for user' products results filter

Terms filter: Is term restricted for current user

Hide/show terms that are restricted for current shop user.

To set such a filter open the plugin settings page -> Search Results tab and find Filter Results section. Click on Filter taxonomies archive pages results button and then choose Woo Memberships: Is term restricted for user rule. Set compare operator and value ( Yes or No ) depending on your needs.

'Woo Memberships: Is term restricted for user' terms results filter

'Woo Memberships: Is term restricted for user' terms results filter

Users filter: User is member

Hide/show users that has a specific membership plan.

To set such a filter open the plugin settings page -> Search Results tab and find Filter Results section. Click on Filter users archive pages search results button and then choose Woo Memberships: User is member rule. Set compare operator and value ( membership plan ) depending on your needs.

'Woo Memberships: User is member' users results filter

'Woo Memberships: User is member' users results filter

Current user filter: Current user is member

Hide/show products/terms/users results based on current user membership plan.

To set such a filter open the plugin settings page -> Search Results tab and find Filter Results section. You can set these filters for any type of search results - products, terms, users. Choose any that you need and set Woo Memberships: Current user is member rule. Set compare operator and needed value ( membership plan ).

'Woo Memberships: Current user is member' results filter

'Woo Memberships: Current user is member' results filter

One of the features of Advanced Woo Search PRO is the option to search and display for all shop users.

When combining this feature together with WooCommerce Memberships plugin advanced integration you can create very interesting and complex things.

Examples of use:
- Search only for users with specific membership plans.
- Allow such searching only for users with specific membership plans.

Below we will cover the steps to enable users search and limit such searching to specific user membership plans:

1. Go to Adv. Woo Search -> Search Results and find Archive pages option. Enable Users field here.

Enabling users search option

Enabling users search option

2. Click on the gear icon near this Users field. Inside the next page you need to specify user roles that must be available for searching. Enable any roles that you need.

Enabling user roles

Enabling user roles

3. We are done. Now you can search for shop users according to specified user roles.

Users search results

Users search results

We enable users' search feature. Now let's look at some examples of search results filters use.

Example: Allow to search for users with specific membership plans

1. Open plugin settings page -> Search Results tab. Scroll down to Filter Results section.

2. Set a new filtering rule for Users results:

Woo Memberships: User is member -> equal to -> {Choose your membership plan}

Search results filter based on user membership plan

Search results filter based on user membership plan

In our example we allow users to search only for users with membership plan VIP Membership. Set it to any other that you need.

3. Save all changes and check your search form - now it must search only for users with specific membership plans.

Search results limited to specific membership plans

Search results limited to specific membership plans