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.
Hi,
I love this module and its UI, but I also need to be able to set individual node permissions programmatically.
Could you please provide a code snippet to set given node's view and edit permissions in PHP?
Thanks!
Comments
Comment #1
good_man CreditAttribution: good_man commentedRelated #1145984: API Documentaion
Comment #2
tterranigma CreditAttribution: tterranigma commentedHere is a function for Drupal 7 that will grant view access to a given user:
Comment #3
gisle