- February 12, 2020 at 6:38 am #94816
Thanks for the great plugin! I’m using it to manage several custom user roles and it’s been working very well. The one issue I’m having is with the media permissions/capabilities. I don’t want users to be able to see each other’s media in the media library, so I’ve unchecked the “read_others_attachments” capability which solves that issue. Unfortunately, that also prevents them from being able to see a media attachment page on the front end (which is viewable to the public/non-logged in user). If the user logs out, they can see the attachment page.
Is there a code snippet that will ensure all users can view the media attachment page even with the “read_others_attachments” capability unchecked?
Thanks!February 12, 2020 at 11:20 pm #94835
That functionality was designed to work like that. It is a bit tricky to manage it with extra code, because it works by modifying the SQL issued by WordPress to exclude others media data. Since we do not get the data from DB, its not possible to work on it after that. I’ll check if there is some way to do this.
SyamFebruary 13, 2020 at 6:14 am #94852
Let me know if there if you come up with any fix. I understand that this is designed behavior and works very well for the back end media library, but it does seem odd to restrict access to the front-end media attachment page since this is viewable by public users that aren’t logged in.
You must be logged in to reply to this topic.