You are here

function name_additional_content_theme in Name Field 6

1 call to name_additional_content_theme()
name_theme in ./name.module
Implement hook_theme().

File

./name.module, line 524
Defines an API for displaying and inputing names.

Code

function name_additional_content_theme(&$theme) {

  // The default CCK formatter. The other theme callbacks
  // are defined dynamically from the database.
  $theme['name_formatter_default'] = array(
    'arguments' => array(
      'element' => NULL,
    ),
  );

  // Additional CCK formatter callbacks.
  $base_info = array(
    'arguments' => array(
      'element' => NULL,
    ),
    'function' => 'theme_name_formatter_default',
  );
  foreach (_name_formatter_output_types() as $type => $title) {
    if ($type != 'default') {
      $theme['name_formatter_' . $type] = $base_info;
    }
    foreach (name_get_custom_format_options() as $machine_name => $name_title) {
      $theme['name_formatter_' . $type . '_' . $machine_name] = $base_info;
    }
  }
}