This recipe allows you to set a specific window of time for membership registration. Anyone who tries to checkout for the level after your specified cutoff date will be shown a message that registration has ended. The level will also be removed from display on your “Membership Levels” page after the cutoff date.
About the Recipe
Some sites need to offer a specific enrollment period, perhaps for a specific session of a class or other training event. Using this recipe, existing members of the level will maintain their accounts through the term or lifetime of their membership.
If you decide to reopen registration at a later date, simply update or remove this customization and uncheck “Disable New Signups” on the Memberships > Settings > Membership Levels > Edit admin page.
The Code Recipe
Adding the recipe to your website
Copy and paste this code recipe into a helper PMPro Customizations plugin. Change line 6 to the ID of your membership level and line 7 to the date the membership stops being offered in YYYY/MM/DD format.
This code recipe was written by our very own Jessica Thomas.