Give Editor Access To WordPress Sidebar

If you want to give the Editor Role access to editing the sidebar and it’s contents.

The edit_theme_options capability should allow the user to edit the sidebar as described on this page :

Code to add to functions.php

$role = get_role('editor'); 

or, you can use Members plugin to create/manage other roles and modify the capabilities.

This should work to prevent editor accessing themes or menus

function custom_admin_menu(){

    $user =new WP_User(get_current_user_id());if(!empty( $user->roles)&& is_array($user->roles)){foreach($user->roles as $role)
            $role = $role;}if($role =="editor"){ 


Leave a Reply

Please log in using one of these methods to post your comment: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.