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
<?php | |
/** | |
* This recipe adds a custom message per membership level to PMPro_Approvals email data. | |
*. ADDED - Custom Shortcode to add to Subject Line !!custom_subject!! | |
* This recipe assumes that the !!custom_approved_message!! variable was added to the | |
* Approvals - Approved Email template, and | |
* the !!custom_denied_message!! variable was added to the | |
* Approvals - Denied Email template. | |
* | |
* You can add this recipe to your site by creating a custom plugin |
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
<?php | |
/** | |
* Move custom date field above address 1 line. | |
*/ | |
function pmpro_move_custom_to_billing() { | |
if ( is_page( 'membership-checkout' ) && wp_script_is( 'jquery', 'done' ) ) { | |
?> | |
<script> | |
jQuery( '#date_of_birth_div' ).prependTo( '.pmpro_checkout-field-baddress1' ); | |
</script> |
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
<?php | |
/** | |
* Change text for the Return To Home and Return to Account for PMPro Advanced Levels add-on. | |
* Add the following code to your PMPro Customizations Plugin - https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/ | |
*/ | |
function pmpro_change_text_for_card( $translated_text, $text, $domain ){ | |
switch ( $translated_text ) { |
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
<?php | |
/** | |
* This recipe will redirect free level (1) to the levels page after registering | |
* | |
* 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. | |
* https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/ | |
*/ | |
function my_pmpro_confirmation_url( $url, $user_id, $level ) { |
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
<?php | |
//Add the group code column to the Order CSV export | |
//Set up the column header and callback function | |
function my_pmpro_orders_csv_extra_columns($columns) | |
{ | |
$columns["group_code"] = "my_extra_order_column_notes"; | |
return $columns; | |
} |
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
<?php | |
/* | |
Plugin Name: PMPro Customizations | |
Plugin URI: https://www.paidmembershipspro.com/wp/pmpro-customizations/ | |
Description: Customizations for my Paid Memberships Pro Setup | |
Version: .1 | |
Author: Paid Memberships Pro | |
Author URI: https://www.paidmembershipspro.com | |
*/ |
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
<?php // This is a fork that ensures results will export | |
/* | |
Add ability to search on specific user and user meta fields | |
in the members list page. | |
e.g. last_name:coleman will search for users with last_name LIKE %coleman% | |
Some common PMPro-related user and user meta fields: | |
* first_name, last_name, user_login | |
* pmpro_bfirstname, pmpro_blastname, pmpro_baddress1, pmpro_bcity, pmpro_bstate, pmpro_bcountry, pmpro_bphone |
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
<?php // do not copy this line. | |
/** | |
* This recipe will let you add hints to default WordPress fields (also child sponsor fields) | |
* | |
* 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. | |
* https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/ | |
*/ |
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
<?php | |
/** | |
* This recipe will change the word 'seat' to 'account' | |
* | |
* 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. | |
* https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/ | |
*/ |