How to Password Protect WordPress Content based on Levels

Requirements:

In this tutorial, we will walk you through the following sections:

How to create password access levels

Step 1: Create a base

Once installing and activating PPWP Access Levels extension successfully, go to Password Protect WordPress >> Access Levels page from your admin panel.

Click on Add New button to create a new base.

It will bring up a new page where you can add a base name (required) and a base description (optional).

Currently, we just support to protect Categories of WordPress Posts so that Post Type option is disabled.

Step 2: Order categories based on levels

After creating a base, click on Manage button link and add the categories that you want to protect to this base.

You can also protect these content by levels. Content under a specific level will be unlocked by a password in the equal or higher levels.

Because “Markup” category isn’t added to any levels, it will be assigned to Level 0 by default.

Unselected categories are assigned to Level 0 by default. That means their content will be unlocked by any passwords in any levels.

Step 3: Create password access levels

Once you select a category to a base, all content under this category will be password protected, including the new one. To unlock these content, you need to create a password with the corresponding level.

Switch to Add New Password tab and generate a password with these pieces of information:

  1. Password requirements: unique, no space, case-sensitive and limited to 100 characters
  2. Label: Allow to give some extra information for your password, e.g. what it is used for?
  3. Password Level: assign a level to this password. Higher-level passwords can unlock all content in the equal or lower levels.
  4. Password Type:
    • Global (default): anyone with the password can unlock the protected group content
    • Roles: only specific user roles are able to use the password to access the private group
      • Let’s say you set a password with type Role (editor)
        • Only editors can use this password to unlock your group
        • Other roles, e.g. subscribers, will receive an error message when entering it into password form
  5. Usage Limit: the maximum number of times a password is used.
    • Let’s assume that the usage limit of a password is set to 1. If a user enters that password to unlock the group, the others can’t use it any more.
    • This feature proves useful to prevent others from sharing your passwords without permission.
  6. Password Expiry: Another way to stop the users from abusing your password is to make it auto-expire after a period of time. In other words, they can’t use that password to unlock your content after a given time.

After creating a new secure password successfully, you will be redirected to the Manage Passwords tab, where you can see and manage all your created passwords.

How password access levels work

Password access levels is a system in which higher-level passwords can unlock all content in the equal or lower levels. For example, you can use password level 2 to unlock all content belonging to categories in level 2, 1 and 0.

Features in brief

  • Support Categories of WordPress Posts
    • If your custom post type uses built-in WordPress Categoires, you have to add this post type to PPWP Pro Post Type Protection (under settings page) to protect it by this extension.
  • Support to create one base only
  • Allow to select main (parent) categories only
  • Unable to remove a selected category from Base once levels are created
  • Have to select at least one category before adding new level
  • Have to delete levels in order. In other words, you can’t remove level 1 if level 2 still exists.
  • Deleting a level will remove all passwords that it is associated with
  • Allow to create multiple passwords in a specific level
Lasted updated on December 3, 2019