Last active
April 10, 2023 12:51
-
-
Save strangerstudios/9049646 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
//Add links to the top of the list | |
function my_pmpro_member_links_top() | |
{ | |
//Add the level IDs here | |
if(pmpro_hasMembershipLevel(array(1,2,3))) | |
{ | |
//Add the links in <li> format here | |
?> | |
<li><a href="/top/">My Member Link Top</a></li> | |
<?php | |
} | |
} | |
add_filter('pmpro_member_links_top','my_pmpro_member_links_top'); | |
//Add links to the bottom of the list | |
function my_pmpro_member_links_bottom() | |
{ | |
//Add the level IDs here | |
if(pmpro_hasMembershipLevel(array(1,2,3))) | |
{ | |
//Add the links in <li> format here | |
?> | |
<li><a href="/bottom/">My Member Link Bottom</a></li> | |
<?php | |
} | |
} | |
add_filter('pmpro_member_links_bottom','my_pmpro_member_links_bottom'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
An updated recipe for this is available here: https://github.com/strangerstudios/pmpro-snippets-library/blob/dev/frontend-pages/add-members-links-to-members-account-page.php