function statistics_advanced_var in Statistics Advanced 6
Internal implementation of variable_get().
4 calls to statistics_advanced_var()
- statistics_advanced_boot in ./
statistics_advanced.module - Implementation of hook_boot().
- statistics_advanced_exit in ./
statistics_advanced.module - Implementation of hook_exit().
- statistics_advanced_link_alter in ./
statistics_advanced.module - Implementation of hook_link_alter().
- statistics_advanced_settings_form in ./
statistics_advanced.admin.inc - Administration settings form.
File
- ./
statistics_advanced.module, line 274 - Adds advanced settings and features for the core Statistics module.
Code
function statistics_advanced_var($name, $default = NULL) {
static $defaults = NULL;
if (!isset($defaults)) {
$defaults = statistics_advanced_variables();
}
$name = 'statistics_advanced_' . $name;
if (!isset($defaults[$name])) {
trigger_error(t('Default variable for %variable not found.', array(
'%variable' => $name,
)));
}
return variable_get($name, isset($default) || !isset($defaults[$name]) ? $default : $defaults[$name]);
}