0

This is for Drupal 6.

I have a module that creates a custom node type called program. I have a role called "marketing" and it has a permission entitled "edit marketing copy"

I've used hook_access to grant update permissions to users who meet this criteria, but the edit tab does not appear on the content when I view it.

function programs_access($op, $node, $account) {
    switch($op) {
        case 'update':
            if(user_access('administer programs', $account) || user_access('edit marketing copy', $account)) {
                return TRUE;
            }
        case 'delete':
        case 'create':
            if(user_access('administer programs', $account)) return TRUE;
    }
}

I know that the user has the permission because the view template shows specific things based on permissions and those work as intended. I just do not receive the "edit tab"

How do I make the edit tab appear on the page for the user? What am I missing?

1

Check if the user has permissions to use that node's input filter.

If that is OK, try rebuilding the content permissions.

1
  • Glad it helped - I was in the same situation quite a few times :) Jul 13 '12 at 20:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.