Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
All of my site image nodes are unpublished because they are only used with image_attach or img_assis inside other pages. This is working well.
However, I need to grant authority for content writers and moderators to be able to view the unpublished image nodes. Giving them 'administer nodes' is too dangerous as it gives much more authority than they should have. Hence I have written a modification which creates a new permission 'view unpublished images' and uses it in image_access() with a new $op case of 'view' to return the correct result to node_access()
Comment | File | Size | Author |
---|---|---|---|
#1 | _1018558.2.image_.view_unpublished_images-d6.patch | 1.09 KB | jonathan1055 |
Comments
Comment #1
jonathan1055 CreditAttribution: jonathan1055 commentedHere is the patch against 1.1