rcp_is_restricted_content( $post_id )

This function will check whether the given post has some kind of restrictions applied to it, whether it's subscription level, access level, role, etc. This also checks if a post is restricted via term and will return true if so.


  • $post_id - ID of the post you'd like to check.

Return values:

  • true if the post has any kind of restrictions assigned to it, or is assigned to a term that is restricted.
  • false if the post does not have any restrictions.
Powered by Zendesk