You are here

function backports_form_field_ui_field_overview_form_alter in Backports 7

Implements hook_form_FORM_ID_alter().

File

./backports.module, line 78
backports.module Hook implementations for Backports.

Code

function backports_form_field_ui_field_overview_form_alter(&$form, &$form_state) {

  // On the field overview screen, instead of linking each field name to the
  // field settings page, just print the field name directly (since the link
  // would now go to the same places that the "edit" link does).
  $fields =& $form['fields'];
  foreach (element_children($fields) as $field) {
    if (isset($fields[$field]['type']['#type']) && $fields[$field]['type']['#type'] == 'link') {
      $fields[$field]['type']['#type'] = 'markup';
      $fields[$field]['type']['#markup'] = check_plain($fields[$field]['type']['#title']);
    }
  }
}