• Hi
    Thanks for the plugin.
    I want to enable new role (Only custom post type editor) to edit images metadata in the media library (Title and alt).
    I don’t want to allow this role to edit all site’s posts, so I can’t grant it “edit_posts” capability.

    Thanks
    Rani

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Vladimir Garagulya

    (@shinephp)

    Hi,

    ‘upload_files’ is required to access to “Media Library’. In order to edit media library item user should can edit the post, to which this item attached. So if custom post type uses its own capabilities like ‘edit_videos’, then those capabilities will be enough.
    In case custom post type uses ‘edit_posts’ capabilities, on of the possible workarounds to use User Role Editor Pro ‘Admin menu access‘ add-on, which allows to block access to the ‘Posts’ menu for user with ‘edit_posts’ capability.

    Another workaround possible with User Role Editor Pro is to “force custom post types to use their own capabilities’. With this option turned ON Media library will use ‘edit_attachments’ capability, instead of ‘edit_posts’, and any custom post type defined at a site will use its own capabilities set, like ‘edit_videos’, ‘edit_events’, etc., instead of built-in ‘edit_posts’.

    Thread Starter jabcka

    (@jabcka)

    Thanks
    The user uses the custom post type capabilities and still can’t edit the images of the posts he’d added.
    Should I add something in the functions.php file or should I consider upgrade to the pro version?
    Rani

    Plugin Author Vladimir Garagulya

    (@shinephp)

    Hi Rani,

    Thanks for this note. You are correct. I rechecked and ‘edit_posts’ is required by default in order user can edit media library item even in case it was attached to another post type.

    So you can resolve your task with the User Role Editor Pro using a variant of solution (admin menu access or own capabilities set for attachments) which is more suitable for your needs and setup.

    Thread Starter jabcka

    (@jabcka)

    Thanks
    Rani

    Look like a trac ticket was opened five years ago to address this issue. I’m also running upon this today and would love to see some resolution.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Allow new role to edit uploaded media data’ is closed to new replies.