You are here

function attachment_links_field_extra_fields in Attachment Links 7

Implements hook_field_extra_fields().

File

./attachment_links.module, line 343

Code

function attachment_links_field_extra_fields() {
  $types = node_type_get_types();
  foreach ($types as $key => $type) {
    if (variable_get('attachment_links_selection_' . $key, 0)) {
      $extra['node'][$key] = array(
        'display' => array(
          'attachment_links' => array(
            'label' => t('Attachment links'),
            'description' => t('Links to the canonical or preferred version of the attached files.'),
            'weight' => 3,
          ),
        ),
      );
    }
  }
  if (isset($extra)) {
    return $extra;
  }
}