• Hi, I would like the option to show media uploaded by certain authors only. Would this be easy to implement? I love the plugin!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Dan Rossiter

    (@danrossiter)

    Hi Andrew,

    That’s an interesting question. This wouldn’t be easy, but not impossible.

    Can you describe the use case you have where only uploads from certain editors would make sense? If I understand more what you’re trying to achieve I may be able to come up with another way to approach your end goal.

    -Dan

    Thread Starter andrewh2016

    (@andrewh2016)

    Hi Dan,

    Thanks for replying. I use Document Gallery to display a page of PDFs that match a Media Category created with Enhanced Media Library. E.g. the Media Category is “Newsletters” and my Document Gallery shortcode contains media_category=”Newsletters” as this is implemented as a custom taxonomy.

    On my site the user “schooloffice” uploads a weekly newsletter to the media library & ticks “Newsletters” in Media Categories. This is then displayed on the correct page. I can find no way of preventing them from selecting other Media Categories e.g. ‘Policies’ as this would cause the file to be displayed on other pages which I do not wish to give them access to & I want to reduce the risk of mistakes.

    If I could include something like author=”admin” on the policies page then even if they did tick the wrong Media Category the file would never be displayed there.

    Before I found Document Gallery, I achieved the same result by customising the page template my own PHP & using WP_Query. I would expect to be able to use the author parameters available in WP_Query to achieve this, although I have not tried it.

    Document Gallery has allowed me to quickly insert a shortcode into my pages rather than have to create a custom page template & insert PHP code, which is tedious & more difficult to maintain. Here’s one example of where I’m using it: https://parklandjunior.theparklandfederation.org/newsletters-archive/

    Andrew

    Plugin Author Dan Rossiter

    (@danrossiter)

    Andrew,

    What if you limit the policies included to just files uploaded to that page? Same for any similar galleries. Just include the id=-1 attribute in your shortcode. That should prevent matching attachments with the correct category, but on the wrong page.

    -Dan

    Thread Starter andrewh2016

    (@andrewh2016)

    Hi Dan,

    At the moment the school user uploads the file to the media library & ticks a media category – they don’t even need to upload it to a page. I don’t want to make it more complicated for them!
    Also they could attach it to the wrong page?

    One thing I could do is use the normal WordPress categories instead of media categories (Enhanced Media Library allows this) and then there are plugins which restrict which category the user can select. I’m trying to avoid this though as I want to keep WordPress categories to organise posts and media categories to organise the media.

    Andrew

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Option to select by author(s)’ is closed to new replies.