You are here

function taxonomy_test_taxonomy_term_view in Drupal 7

Implements hook_taxonomy_term_view().

File

modules/simpletest/tests/taxonomy_test.module, line 62
Test module for Taxonomy hooks and functions not used in core.

Code

function taxonomy_test_taxonomy_term_view($term, $view_mode, $langcode) {
  if ($view_mode == 'full') {
    $term->content['taxonomy_test_term_view_check'] = array(
      '#prefix' => '<div>',
      '#markup' => t('The antonym is %antonym', array(
        '%antonym' => $term->antonym,
      )),
      '#suffix' => '</div>',
      '#weight' => 10,
    );
  }
}