Answer the question
In order to leave comments, you need to log in
How to show content only to authorized WordPress users?
It is necessary to register content closure for unauthorized users directly in the php file template, I found on the Internet only ways to close content through shortcodes, which does not work accordingly ((
Answer the question
In order to leave comments, you need to log in
Hello. WP has a function is_user_logged_in() use it to create a shortcode that will display the content.
You can make it even easier with the YITH WooCommerce Membership Premium plugin. Create at least a dozen user groups with different views.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question