• Resolved dropshot

    (@dropshot)


    In the post editor, clicking the add media button… Editors can’t add images from the Media Library. They can’t even see them.

    If I change the user role to Admin this works fine. The user can see all images in the library and add from them into the post.

    But it’s not possible in this case to let the Editor role access everything, but still I want them to add images from the library.

    Any suggestions?

Viewing 9 replies - 1 through 9 (of 9 total)
  • Have you changed any of the Editor role’s capabilities or what they can see in the Admin Dashboard?

    Thread Starter dropshot

    (@dropshot)

    Thank you for replying Sandy!
    (didn’t see it until now, didn’t get the email notification)

    I have some hide-if-not-admin code in my functions.php
    But deleting them did no difference.

    What I found though is that everything works fine on mamp/localhost.

    So I guess the issue is with my web host? Is there something I can check and edit myself?

    I had a similar issue previously. Did you migrate this site from your local environment to your hosting provider?

    Try setting up a brand new user with the editor role. In my case I only had one editor user so I setup a new account and it worked fine. Then I deleted the old account and transferred all posts etc to the new account I setup.

    This seemed to fix it for me.

    Thread Starter dropshot

    (@dropshot)

    Additional info:

    Editor can see all images from menu item Media Library. But when in post editor and add media Editor can’t see anything in Media Library. Not even images that they have uploaded.

    When trying to edit an image from menu item Media Library Editor get this message:

    Warning: Invalid argument supplied for foreach() in /home/u/mywebhostaccount/www/victoria/wp-admin/includes/plugin.php on line 1395

    Admin can edit images without problem.

    On localhost Editor can edit images.

    Did you try setting up a new user?

    Thread Starter dropshot

    (@dropshot)

    Thanks again Sandy.

    Tried your fix adding a new editor. That didn’t work. The new editor has the same issues.

    Then I did a little search and wp-admin/includes/plugin.php on line 1395 includes remove_menu_page

    So I searched my functions file for the same. What I did find was another hide-from-nonadmin snippet. I forgot I had it.

    add_action('admin_init', 'remove_menus');
    function remove_menus(){
    	if(!current_user_can('add_users')){
    		remove_menu_page('jetpack');
    	}
    }

    It obviously hides Jetpack from non admins. When I deleted this the problem was solved.

    But then Editors can access Jetpack and all its options. I really don’t want that. So I need to find another way to hide it I guess… So, now I have another problem.

    Not sure this will work or not but try using admin_menu instead of admin_init

    Thread Starter dropshot

    (@dropshot)

    That didn’t really do anything. It didn’t hide Jetpack from the menu, but it didn’t either mess up the Editors access to Media Library.

    I will mark this as solved and start a new thread for the Jetpack-menu-issue if I can’t find another solution.

    Thanks for your help Sandy!

    I hope someone can help me. I cannot add photos from the library. I can’t even see the photos in my library. I am the administrator. I don’t have a clue what’s wrong.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Editors can't add media from Media Library’ is closed to new replies.