LLMS_Post_Types::add_membership_restriction_support()
Add post type support for membership restrictions
Description Description
This enables the "Membership Access" metabox to display
Return Return
(void)
Source Source
File: includes/class.llms.post-types.php
public static function add_membership_restriction_support() { /** * Add llms-membership-restrictions support for the following post types. * * Adding support for a post type enables the display of the Membership Restriction metabox * for each specified post type. * * These post types can then be "restricted" to enrollment in the selected memberships. * * @since Unknown * * @param string[] $post_types Array of post type names. */ $post_types = apply_filters( 'llms_membership_restricted_post_types', array( 'post', 'page' ) ); foreach ( $post_types as $post_type ) { add_post_type_support( $post_type, 'llms-membership-restrictions' ); } }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
3.0.4 | Unknown. |
3.0.0 | Introduced. |