Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save ipokkel/4f1684b0cff5b4ab455c54e1cca5c76d to your computer and use it in GitHub Desktop.
Save ipokkel/4f1684b0cff5b4ab455c54e1cca5c76d to your computer and use it in GitHub Desktop.
Adjust the Paid Memberships Pro login "Join Now" Link.
<?php
/**
* Adjust the 'Join Now' link on the login page to a custom URL for Paid Memberships Pro.
* Follow this guide to add custom code to your membership site - https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/
*/
function my_pmpro_custom_join_now_link( $links, $allowed_html ) {
$links['register'] = '<a href="https://example.com/join-now/">' . __( 'Join Now', 'paid-memberships-pro' ) . '</a>';
return $links;
}
add_filter( 'pmpro_login_forms_handler_nav', 'my_pmpro_custom_join_now_link', 10, 2 );
@ipokkel
Copy link
Author

ipokkel commented Feb 27, 2024

Hey, awesome codes data base you have!! Does this work with modal logins like Tagdiv Composer or Visual Composer?

No, this specifically hooks into the PMPro login form only.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment