function location_node_content_extra_save in Location 6.3
Same name and namespace in other branches
- 7.3 location_node.module \location_node_content_extra_save()
- 7.4 location_node.module \location_node_content_extra_save()
Saving the fields management's weight for location node data in forms and node view
_state
Parameters
$form:
1 string reference to 'location_node_content_extra_save'
- location_node_form_content_field_overview_form_alter in ./
location_node.module - Alter the content_field_overview_form form.
File
- ./
location_node.module, line 224 - Associate locations with nodes.
Code
function location_node_content_extra_save($form, &$form_state) {
$type = $form['#type_name'];
// We need to stay in sync with CCK's idea of the weight.
$settings = variable_get('location_settings_node_' . $type, array());
if (isset($form_state['values']['locations'])) {
$settings['form']['weight'] = $form_state['values']['locations']['weight'];
$settings['display']['weight'] = $form_state['values']['locations']['weight'];
}
variable_set('location_settings_node_' . $type, $settings);
}