Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save antcms/04374e6bf1ee64717722523a92f63330 to your computer and use it in GitHub Desktop.
Save antcms/04374e6bf1ee64717722523a92f63330 to your computer and use it in GitHub Desktop.
Remove the Category menu for Authors in the WordPress Quick Edit Menu
//REMOVE TAX IN QUICK EDITOR
add_action('admin_head', 'no_tax_display');
function no_tax_display(){
$user = wp_get_current_user();
if ( in_array( 'author', (array) $user->roles ) ) {
echo '<style>
.inline-edit-categories, #acf-form-data {
display: none;
}
</style>';
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment