Quantcast
Channel: WordPress › Support » Forum: Hacks - Recent Topics
Viewing all articles
Browse latest Browse all 8245

3Pinter on "remove editor option for userrole author (and lower)"

$
0
0

So basicly if a user is author or lower there is no need for them to have the editor.

Im using the latest version of WP in a multisite environment.

I have a function that states all the unneeded stuff, which I will hook into WP the correct way. So far so good.

function dio_removals() {
		if ( !current_user_can('manage_links') ) {
		// remove post types
		remove_post_type_support( 'post', 'editor' );
		// remove meta WP version
		}
		remove_action('wp_head', 'wp_generator');
	}

manage_links is something an author-role isn't allowed to do so I thought this should work. But it doesn't. As a superadmin I don't have the editor either now.

What goes wrong / what should I do?


Viewing all articles
Browse latest Browse all 8245

Trending Articles