function content_admin_display_overview_form_submit in Content Construction Kit (CCK) 6
Same name and namespace in other branches
- 5 content_admin.inc \content_admin_display_overview_form_submit()
Submit handler for the display overview form.
File
- includes/
content.admin.inc, line 394 - Administrative interface for content type creation.
Code
function content_admin_display_overview_form_submit($form, &$form_state) {
module_load_include('inc', 'content', 'includes/content.crud');
$form_values = $form_state['values'];
$fields = content_fields();
foreach ($form_values as $key => $values) {
// Groups are handled in fieldgroup_display_overview_form_submit().
if (in_array($key, $form['#fields'])) {
$field = content_fields($key, $form['#type_name']);
// We have numeric keys here, so we can't use array_merge.
$field['display_settings'] = $values + $field['display_settings'];
$field = content_field_instance_collapse($field);
content_field_instance_update($field);
}
content_clear_type_cache();
}
drupal_set_message(t('Your settings have been saved.'));
}