function comment_perm_post_access in Comment Permissions 7.2
Determine access to post comments for current node type.
Parameters
object $node: Node object.
Return value
bool TRUE - Current node type has permission access, FALSE otherwise.
3 calls to comment_perm_post_access()
- comment_perm_comment_view_alter in ./
comment_perm.module - Implements hook_comment_view_alter().
- comment_perm_form_alter in ./
comment_perm.module - Implements hook_form_alter().
- comment_perm_node_view_alter in ./
comment_perm.module - Implements hook_node_view_alter().
File
- ./
comment_perm.module, line 275 - Control commenting permissions by role and by node type.
Code
function comment_perm_post_access($node) {
return user_access("post comments {$node->type}");
}