theme_taxonomy_term_page
modules/taxonomy/taxonomy.pages.inc, строка 87
- Версии
- 6
theme_taxonomy_term_page($tids, $result)
Рендерит HTML-представление страницы термина таксономии.
Параметры
$tids
Массив идентификаторов терминов.
$result
Результат функции pager_query(), например, возвращенный из taxonomy_select_nodes().
Связанные темы
Код
<?php
function theme_taxonomy_term_page($tids, $result) {
drupal_add_css(drupal_get_path('module', 'taxonomy') .'/taxonomy.css');
$output = '';
// Only display the description if we have a single term, to avoid clutter and confusion.
if (count($tids) == 1) {
$term = taxonomy_get_term($tids[0]);
$description = $term->description;
// Check that a description is set.
if (!empty($description)) {
$output .= '<div class="taxonomy-term-description">';
$output .= filter_xss_admin($description);
$output .= '</div>';
}
}
$output .= taxonomy_render_nodes($result);
return $output;
}
?>
Войдите или зарегистрируйтесь, чтобы получить возможность отправлять комментарии