Skip to main content

mbr_is_allowed_access

Usage​

This shortcode determines the content to be included based upon whether the visitor has access to a specified page/post.

It has many use cases and can be particularly useful when used in conjunction with [mbr_page]/[mbr_post] to combine various content elements into a another page/post.

Parameters​

ParametersDescription
post_idThe page or post ID for which to check the current visitor's access conditions.
Default: Current page/post post_id.
Required: no.
limit_elseIf set to "yes" and the user is not logged in or does not have any ActiveCampaign contact tags that define a membership as selected in ActiveMember360, Settings, Memberships this parameter will cause the "ELSE" part of the shortcode to be suppressed. This can be useful in scenarios where the "ELSE" portion of the shortcode is only applicable to members of the site, for example excluding visitors who are not logged in.
Default: no.
Required: no.

Validity​

This shortcode is evaluated for any type of visitor.

Conditional Branching​

[ELSE_is_allowed_access] conditional branching is supported.

Nesting​

Shortcode nesting is NOT supported.

Examples​

Will display "Display this content as allowed access." if the visitor is logged in and satisfy the conditions to access the current page/post where the shortcode is used:

[mbr_is_allowed_access]
Display this content as allowed access.
[/mbr_is_allowed_access]

API​

Note

There is no ActiveMember360 API function equivalent for this shortcode. Please use standard PHP functions.