Just upgraded to WordPress 4.4 and I notice now my users’ profile page in admin, there’s a section called “profile picture”, with a link to Gravatar.
The plugin I’m developing restricts a lot of things in profile.php; unfortunately by deleting from the DOM via jQuery:
jQuery( document ).ready(function() {
jQuery( "h2:contains('Personal Options')" ).remove();
jQuery( "h2:contains('Name')" ).remove();
jQuery( "h2:contains('Contact Info')" ).remove();
jQuery( "h2:contains('About Yourself')" ).remove();
jQuery( "h2:contains('Account Management')" ).remove();
jQuery( "tr.show-admin-bar" ).parents("table:first").remove();
jQuery( "tr.user-first-name-wrap" ).remove();
jQuery( "tr.user-last-name-wrap" ).remove();
jQuery( "tr.user-nickname-wrap" ).remove();
jQuery( "tr.user-display-name-wrap" ).remove();
jQuery( "tr.user-url-wrap" ).remove();
jQuery( "tr.user-description-wrap").parents("table:first").remove();
jQuery( ".user-sessions-wrap" ).remove();
});
Before I continue on the jQuery addiction, is there a better way to do this (aside from output buffer replacement)? Also, is there some other setting specifically for the user profile picture, or is this jQuery solution going to be the answer for now?