function _location_taxonomize_variables in Location Taxonomize 7
Same name and namespace in other branches
- 7.2 location_taxonomize.inc \_location_taxonomize_variables()
Keeps a list of all the variables maintained by this module, with their default values.
2 calls to _location_taxonomize_variables()
- _location_taxonomize_del_variables in ./
location_taxonomize.inc - Deletes all variables set by this module
- _location_taxonomize_set_defaults in ./
location_taxonomize.inc - Sets all this module's variables to their default values
File
- ./
location_taxonomize.inc, line 26 - Some useful functions for Location taxonomize
Code
function _location_taxonomize_variables() {
$fields = _get_location_fields();
// set field defaults
foreach ($fields as $key => $value) {
if ($key != 'country' && $key != 'province' && $key != 'city') {
$fields[$key] = 0;
}
}
return array(
'location_taxonomize_vid' => NULL,
'location_taxonomize_vocab' => array(
'method' => 'existing',
'possible_vid' => NULL,
'fields' => $fields,
),
'location_taxonomize_settings' => array(
'enable' => 1,
'naming' => array(
'country' => 'name',
'province' => 'name',
'usa' => 1,
),
'na_text' => 'Unknown',
'longname_enable' => 0,
'longname' => array(
// this is set by the initialization process
'fields' => NULL,
'separator' => ',',
'country_naming' => 'code',
'province_naming' => 'code',
'usa' => 1,
),
),
);
}