PMPro’s Membership Account page displays several important sections, including membership details, profile info, past invoices, and a customizable list of Member Links.
In this code recipe, we show you how to insert new Member Links to the account page using two action hooks in the plugin. These links can be added for all members or for members of a specific membership level.
Available Hooks for the Member Links Section
You can use these hooks in combination with the pmpro_hasMembershipLevel()
function to check a user’s level before displaying links.
Note that in order for the “Member Links” section to display on your account page you must be sure to include the “links” section in the shortcode on the page or add it via the block method.
This is one method you can use to create a more useful “dashboard” for your members. Check out this article with more information to help you create a powerful Membership Account page.
The Code Recipe
Adding the Recipe to Your Website
You can add this recipe to your site by creating a custom plugin or using the Code Snippets plugin available for free in the WordPress repository. Read this companion article for step-by-step directions on either method.
After setting up the code, you can modify the list items to add the appropriate links you need for your membership site.
Related Reading: How to Customize the Frontend Pages
We have a few articles in our blog on how to adjust the appearance of your frontend membership pages. Check the links below to explore the guides:
- Making a Powerful Member Dashboard for Your Membership Account Page
- Create a Dual Login and Benefits of Registration Page
- How to Create a Custom Membership Level Pricing Page
- Membership Pricing Pages and Streamlining the Checkout Process
- Using Page Builders to Enhance Your Site’s Membership Pages
- Design a Specific Level’s Membership Checkout Page Using CSS
- Customizing the Member Links list on Membership Account Page
- Add Links by Membership Level to the Membership Account Page “links” Section
- Customizing the Member Cancellation Process
- How to Load a Custom Template for Membership Pages or System-Generated Emails
Free Course: Membership Site Development—The Basics
Develop a deeper understanding of membership site development in this beginner-level course. Learn how to make your site work better, save yourself time and money, and improve your site's performance.