Use Content Restriction Shortcodes, when you want to restrict partial contents of a post/page based on user types.
Content Restriction Shortcodes List
This screen displays all the restriction shortcodes available within your site. This screen requires the user to have “edit_content_shortcodes” capability.
Adding a New Shortcode
To add a new shortcode, click on the “Add New” button at the top of the list screen.
You can give a user identifiable name in the Name field to easily identify the shortcode. The Shortcode field is used by WordPress to identify the shortcode and can contain only lowercase letters, numbers and underscore. This field has to be unique.
When you select “Users in Roles”, you will be presented with a list of roles within your site. “Administrator” role included by default and won’t be visible in the list. Use the “[Guest]” role to include users who are not logged into your site.
Editing a Shortcode
Use the “Edit” row action available within the list to edit an existing shortcode.
Deleting a Shortcode
Use the “Delete” row action available within the list to delete an existing shortcode. Alternatively you can use the Bulk Delete option to delete multiple shortcodes at once. User requires “delete_content_shortcode” capability to delete the shortcodes.
Usage
To use a Content Restriction Shortcode, copy the shortcode from the Shortcode column within the list view and paste it where you want to use the shortcode, then your special content will go between the shortcode tags. You can use the shortcode in places, where the WordPress do_shortcode routine is processed, usually within posts/pages.
Ex: [shortcode]Your content goes here.[/shortcode]
You are allowed to use others shortcodes within the shortcode content. So you can create multiple shortcodes and use them together.
Topics
Posts/Pages Extended Permissions
Media/Attachment File Permissions
Content Restriction Shortcodes