How check if current user has pmpro_hasMembershipLevel? Copy and paste the code below to your custom template.
// $levelID is can be name or ID of the membership level // $userID is the ID of the current user pmpro_hasMembershipLevel( $levelID, $userID ); // Example if(pmpro_hasMembershipLevel('12')){ } if(pmpro_hasMembershipLevel('Gold')){ } if(pmpro_hasMembershipLevel(array('12','14','Gold'))){ }
Leave a Reply