You are here

function i18n_taxonomy_field_extra_fields in Internationalization 7

Implements hook_field_extra_fields().

File

i18n_taxonomy/i18n_taxonomy.module, line 249
i18n taxonomy module

Code

function i18n_taxonomy_field_extra_fields() {
  $return = array();
  $info = entity_get_info('taxonomy_term');
  foreach (array_keys($info['bundles']) as $bundle) {
    $vocabulary = taxonomy_vocabulary_machine_name_load($bundle);
    if ($vocabulary && i18n_taxonomy_vocabulary_mode($vocabulary, I18N_MODE_TRANSLATE)) {
      $return['taxonomy_term'][$bundle] = i18n_language_field_extra();
    }
  }
  return $return;
}