Skip to content

Instantly share code, notes, and snippets.

@ajitbohra
Last active October 29, 2020 08:51
Show Gist options
  • Save ajitbohra/54420fd74218badcfa93 to your computer and use it in GitHub Desktop.
Save ajitbohra/54420fd74218badcfa93 to your computer and use it in GitHub Desktop.
Wordpress: Hide yoast seo settngs on user profile https://lubus.in/blog/wordpress-yoast-seo-hide-settings-user-profile-page-19
.yoast-settings {
display: none;
}
<?
// Register Style
function lubus_admin_style() {
wp_register_style( 'admin-style', get_template_directory_uri() .'/admin.css', false, '1.0' );
wp_enqueue_style( 'admin-style' );
}
// Hook into the 'admin_enqueue_scripts' action
add_action( 'admin_enqueue_scripts', 'lubus_admin_style' );
?>
add_action('admin_head', 'lubus_hide_yoast_profile');
function lubus_hide_yoast_profile() {
echo '<style>
.yoast-settings {
display: none;
}
</style>';
}
@matrixhaj
Copy link

how to implement into existing files? :/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment