function content_token_list in Token 5
File
- ./
token_cck.inc, line 30
Code
function content_token_list($type = 'all') {
if ($type == 'node' || $type == 'all') {
$list = array();
$field_types = _content_field_types();
foreach (content_fields() as $field) {
$sub_list = array();
$function = $field_types[$field['type']]['module'] . '_token_list';
if (function_exists($function)) {
$sub_list = $function('field');
foreach ($sub_list as $category => $token_list) {
foreach ($token_list as $token => $description) {
$list['CCK ' . $category][$field['field_name'] . '-' . $token] = $description;
}
}
}
}
return $list;
}
}