Rename the permission
dagmar - February 2, 2008 - 13:10
| Project: | Comment CCK |
| Version: | 6.x-1.x-dev |
| Component: | Code |
| Category: | task |
| Priority: | normal |
| Assigned: | cwgordon7 |
| Status: | closed |
Description
Hello:
Can you add another permission in the implementation of hook_perm()?
Something like this
<?php
/**
* Implementation of hook_perm().
*/
function comment_cck_perm() {
return array('allow fields to be changed', 'use comment cck',);
}
/**
* Implementation of hook_comment()
*/
function comment_cck_comment($comment, $op) {
if(user_access('use comment cck')){
//your comment_cck_comment function code
}
}
?>Then we can set wich roles can use comment cck
Thanks
Mariano

#1
+1 for this
#2
Same here
#3
I am not sure I understand this request: The permission that is implemented does a check in hook_:form_alter already.
#4
I agree that this makes no sense. However, I think that this request comes from a misunderstanding of the very unclear "allow fields to be changed" permission name. Perhaps it should be renamed to something along the lines of "alter cck fields through comments".
#5
#6
applied
#7
Automatically closed -- issue fixed for two weeks with no activity.