function taxonomy_field_extra_fields in Drupal 7
Implements hook_field_extra_fields().
File
- modules/
taxonomy/ taxonomy.module, line 154 - Enables the organization of content into categories.
Code
function taxonomy_field_extra_fields() {
$return = array();
$info = entity_get_info('taxonomy_term');
foreach (array_keys($info['bundles']) as $bundle) {
$return['taxonomy_term'][$bundle] = array(
'form' => array(
'name' => array(
'label' => t('Name'),
'description' => t('Term name textfield'),
'weight' => -5,
),
'description' => array(
'label' => t('Description'),
'description' => t('Term description textarea'),
'weight' => 0,
),
),
'display' => array(
'description' => array(
'label' => t('Description'),
'description' => t('Term description'),
'weight' => 0,
),
),
);
}
return $return;
}