You are here

function _variable_variable in Variable 7

Same name and namespace in other branches
  1. 7.2 variable.module \_variable_variable()

Normalize variable data

Parameters

$variable: Variable name or variable info array

Return value

array Variable information

9 calls to _variable_variable()
theme_variable_table_select in ./variable.form.inc
Form to select variables
variable_access in ./variable.module
Check access to variable
variable_build in ./variable.module
Build full variable data
variable_build_variable in ./variable.inc
Build single variable
variable_delete in ./variable.module
Delete variable (included children variables)

... See full list

File

./variable.module, line 615
Variable API module

Code

function _variable_variable($variable, $options = array()) {
  if (is_array($variable)) {
    return $variable;
  }
  elseif ($info = variable_get_info($variable, $options)) {
    return $info;
  }
  else {

    // We don't have meta-information about this variable.
    return _variable_unknown($variable);
  }
}