function taxonomy_access_fix_permission in Taxonomy access fix 7.2
Same name and namespace in other branches
- 7 taxonomy_access_fix.module \taxonomy_access_fix_permission()
Implements hook_permission().
Adds one permission per vocabulary: 'add terms in VOCABULARY'.
File
- ./
taxonomy_access_fix.module, line 98 - This file contains all hooks and callbacks for extra/improved Taxonomy permissions.
Code
function taxonomy_access_fix_permission() {
$permissions = array();
foreach (taxonomy_get_vocabularies() as $vocabulary) {
$permissions['add terms in ' . $vocabulary->machine_name] = array(
'title' => t('Add terms in %vocabulary', array(
'%vocabulary' => $vocabulary->name,
)),
);
}
return $permissions;
}