Created
May 3, 2021 14:28
-
-
Save andrewlimaza/c95d28bc825817dccaa5bf46b374ab8e to your computer and use it in GitHub Desktop.
Grant user's with level 4 access to all Addon Packages
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 | |
/** | |
* Give user's with level ID 4 free access to all Addon Packages content. | |
* Add this code to your site by following this guide - https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/ | |
*/ | |
function my_pmproap_all_access_levels( $levels ) { | |
$levels = array( 4 ); //change the level ids here | |
return $levels; | |
} | |
add_filter( "pmproap_all_access_levels", "my_pmproap_all_access_levels" ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment