Created
April 3, 2020 16:28
-
-
Save dparker1005/4524ea86308bdf79c7d2fecf3c7264df to your computer and use it in GitHub Desktop.
Removes profile fields added by PMPro Member Directory
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 | |
// Copy from below here... | |
/** | |
* Removes profile fields added by PMPro Member Directory | |
*/ | |
function my_pmpromd_remove_extra_profile_fields() { | |
// Remove showing... | |
remove_action( 'show_user_profile', 'pmpromd_show_extra_profile_fields' ); | |
remove_action( 'edit_user_profile', 'pmpromd_show_extra_profile_fields' ); | |
// Remove saving... | |
remove_action( 'personal_options_update', 'pmpromd_save_extra_profile_fields' ); | |
remove_action( 'edit_user_profile_update', 'pmpromd_save_extra_profile_fields' ); | |
} | |
add_action( 'init', 'my_pmpromd_remove_extra_profile_fields' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment