function taxonomy_title_token_values in Taxonomy Title 6
Implementation of hook_token_values().
File
- ./
taxonomy_title.module, line 265 - Enhanced control over the heading tag for the taxonomy term list pages.
Code
function taxonomy_title_token_values($type, $object = NULL, $options = array()) {
$values = array();
if ($type == 'taxonomy') {
if (!empty($object)) {
$category = $object;
// Use taxonomy title if it exists, else the category name.
$title = _taxonomy_title_get($category->tid);
$values['term-title'] = $title ? check_plain($title) : check_plain($category->name);
$values['term-title-raw'] = $title ? $title : $category->name;
}
}
return $values;
}