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.
i am trying to set up SimpleAds module so that one of my users can view nodes created by advertisements that are added. I have checked all the necessary permissions in the Home » Administration » People screen but it is still giving the user the "Access Denied" error
any feedback on a fix would be appreciated.
Comment | File | Size | Author |
---|---|---|---|
#7 | permission-issue-1795174-2.patch | 578 bytes | yvesvanlaer |
Comments
Comment #1
binaryweb CreditAttribution: binaryweb commentedComment #2
Alexpi CreditAttribution: Alexpi commentedChange this line 152 in simpleads.module:
to this:
Comment #3
minnur CreditAttribution: minnur commentedComment #4
Liliplanet CreditAttribution: Liliplanet commentedperfect, thank you! users can now see their ad ..
Comment #5
minnur CreditAttribution: minnur commentedadded to dev.
Comment #6
Nor4a CreditAttribution: Nor4a commentedThe same issue with 2x.
Now the problem is in the includes/node.inc file - in the "simpleads_node_access" function. Incorrect permission naming.
Change the line:
To the line:
if (isset ($node->type) && $node->type == 'simpleads' && $op == 'view' && !user_access('access advertisement node', $account)) {
Comment #7
yvesvanlaer CreditAttribution: yvesvanlaer commentedI created a patch for this. I think It is about time that this will be committed :).
Comment #9
minnur CreditAttribution: minnur commentedFixed in DEV.
Comment #12
minnur CreditAttribution: minnur as a volunteer commented