Created
September 18, 2018 18:21
-
-
Save kenmasters/da2dbde0fe58231eb4132a3f3c25df44 to your computer and use it in GitHub Desktop.
This file contains 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_filter( 'edit_profile_url', 'custom_profile_url', 10, 3 ); | |
function custom_profile_url( $url, $user_id, $scheme ) { | |
if ( !current_user_can('subscriber') ) return; | |
return ''; | |
} | |
# IMPORTANT NOTES: What the function does above is removing the link on the Edit Profile if the current loggedin user role is `subscriber`. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment