function theme_i18ntaxonomy_term_page in Internationalization 6
Render a taxonomy term page HTML output.
Parameters
$tids: An array of term ids.
$result: A pager_query() result, such as that performed by taxonomy_select_nodes().
1 theme call to theme_i18ntaxonomy_term_page()
- i18ntaxonomy_term_page in i18ntaxonomy/
i18ntaxonomy.pages.inc - Menu callback; displays all nodes associated with a term.
File
- i18ntaxonomy/
i18ntaxonomy.pages.inc, line 91 - Page callbacks for the taxonomy module, i18n remake.
Code
function theme_i18ntaxonomy_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]);
if (i18ntaxonomy_vocabulary($term->vid) == I18N_TAXONOMY_LOCALIZE) {
$description = i18nstrings("taxonomy:term:{$term->tid}:description", $term->description);
}
else {
$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;
}