function ctools_term_ctools_access_summary in Chaos Tool Suite (ctools) 7
Same name and namespace in other branches
- 6 plugins/access/term.inc \ctools_term_ctools_access_summary()
Provide a summary description based upon the checked terms.
1 string reference to 'ctools_term_ctools_access_summary'
File
- plugins/
access/ term.inc, line 115 - Plugin to provide access control based upon specific terms.
Code
function ctools_term_ctools_access_summary($conf, $context) {
$vid = $conf['vid'];
$terms = array();
foreach ($conf[$vid] as $tid) {
$term = taxonomy_term_load($tid);
$terms[] = $term->name;
}
return format_plural(count($terms), '@term can be the term "@terms"', '@term can be one of these terms: @terms', array(
'@terms' => implode(', ', $terms),
'@term' => $context->identifier,
));
}