Created
November 4, 2019 00:15
-
-
Save kimcoleman/8bb3e260615512b41f64d948afb55d7e to your computer and use it in GitHub Desktop.
Filter to add additional post types for protection and individual sale using Addon Packages for Paid Memberships Pro.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Filter to add additional post types for protection and individual sale using Addon Packages for Paid Memberships Pro. | |
* You should also install the Custom Post Type (CPT) Membership Access Add On so that your CPT can be properly restricted. | |
* https://www.paidmembershipspro.com/add-ons/custom-post-type-membership-access/ | |
* | |
*/ | |
function add_new_cpts_pmproap_supported_post_types( $post_types ) { | |
$post_types[] = 'custom_courses'; | |
return $post_types; | |
} | |
add_filter( 'pmproap_supported_post_types', 'add_new_cpts_pmproap_supported_post_types' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment