Displaying special pricing for logged-in users with the Conditional Content plugin

If you are using Dynamic Pricing or some other pricing plugin to create special prices for users, you should display that content to customers. This is especially useful if you have bulk pricing, where the discounts aren't automatically visible to customers. In this recipe, we're going to show a special message to customers who aren't a part of our premium membership and show them how much they could be saving if they were a premium member.

Getting ready

You must have WooCommerce Subscriptions, Dynamic Pricing, and Conditional Content (http://www.woothemes.com/products/woocommerce-conditional-content/) installed and activated on your site.

How to do it…

To display special pricing for logged-in users with conditional content, let's take a look at the following steps:

  1. From the WordPress admin, go to WooCommerce | Content Blocks.
  2. Click on Add Content Block.
    How to do it…
  3. Enter a title for the content block and then add a description.
    How to do it…
  4. Now scroll down to the Rules panel. This is where we'll be using some conditional content logic to only display this message to non-subscribers. In our case, we'll want to create a rule that displays only when a user doesn't have the Subscriber role.
    How to do it…

    Note

    You can combine as many rules as you like by clicking on the and button. You could, for example, add an extra rule to make sure this message doesn't appear for premium subscription products.

  5. Click on Publish.

There's more...

You can not only control when this message is shown with this extension, but you can also control where it's shown. On the Add Content Block page, there's a panel in the sidebar called Output Settings. This allows you to choose how often and where the message gets displayed.

There's more...

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset