function taxonomy_permission
Implements hook_permission().
File
-
modules/
taxonomy/ taxonomy.module, line 67
Code
function taxonomy_permission() {
$permissions = array(
'administer taxonomy' => array(
'title' => t('Administer vocabularies and terms'),
),
);
foreach (taxonomy_get_vocabularies() as $vocabulary) {
$permissions += array(
'edit terms in ' . $vocabulary->vid => array(
'title' => t('Edit terms in %vocabulary', array(
'%vocabulary' => $vocabulary->name,
)),
),
);
$permissions += array(
'delete terms in ' . $vocabulary->vid => array(
'title' => t('Delete terms from %vocabulary', array(
'%vocabulary' => $vocabulary->name,
)),
),
);
}
return $permissions;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.