Limit access with shortcodes
In addition to being able to prevent unauthorized users from visiting certain pages, you can also choose to restrict only select sections of the content.
Good to know: Administrators are by default able to see all content hidden by restriction shortcodes.
Restrict Content Shortcode for Levels
If you have a level with the name “platinum”, you can hide a section for unauthorized users with the following shortcode:
Likewise, if you want to hide a section for level members, use the following code (notice the !):
This content can only be seen by users without Platinum level or above.
If you want exclusively show content to multiple levels that do not extend eachother, you can use commas to separate them:
Important: The level parameter only accepts the level name, not the title or id.
Restrict Content Shortcode for User Roles
Restricting content to roles is done in the same manner as levels, but with a “role” parameter instead.