bp_remove_avatar_settings_from_options_discussion_page()
Adds CSS to remove the Default Avatar settings from /wp-admin/options-discussion.php page.
Description
These settings cannot be used with BuddyBoss, as we load custom avatars instead of gravatar.
Source
File: bp-core/admin/bp-core-admin-functions.php
function bp_remove_avatar_settings_from_options_discussion_page() { global $pagenow; if ( 'options-discussion.php' === $pagenow ) { ?> <style> body.options-discussion-php #wpbody-content .wrap form table:nth-last-child(2) tbody tr:last-child { display: none !important; } body.options-discussion-php #wpbody-content .wrap h2.title, body.options-discussion-php #wpbody-content .wrap h2.title + p, body.options-discussion-php #wpbody-content .wrap h2.title + p + table { display: none !important; } </style> <?php } }
Changelog
Version | Description |
---|---|
BuddyBoss 1.0.0 | Introduced. |
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.