function location_node_content_extra_fields in Location 6.3
Same name and namespace in other branches
- 7.3 location_node.module \location_node_content_extra_fields()
- 7.4 location_node.module \location_node_content_extra_fields()
Implementation of hook_content_extra_fields().
For being able to edit location weight in node forms and node view.
File
- ./
location_node.module, line 205 - Associate locations with nodes.
Code
function location_node_content_extra_fields($type_name) {
$settings = variable_get('location_settings_node_' . $type_name, array());
if (isset($settings['multiple']) && $settings['multiple']['max'] > 0) {
$weight = isset($settings['form']['weight']) ? $settings['form']['weight'] : 0;
$extra['locations'] = array(
'label' => t('Locations'),
'description' => t('Node Locations module form.'),
'weight' => $weight,
);
return $extra;
}
}