You are here

function variable_base_form in Variable 7.2

Build base form for variable list without fields.

Parameters

$list: List of variable names.

$options: Optional array with variable options.

2 calls to variable_base_form()
variable_edit_form in ./variable.module
Form for variable list
variable_realm_edit_variables_form in variable_realm/variable_realm.form.inc
Edit variables for realm.

File

./variable.module, line 437
Variable API module

Code

function variable_base_form($form, &$form_state, $list, $options = array()) {
  form_load_include($form_state, 'form.inc', 'variable');

  // Pass on the values on the form for further reference.
  $form['#variable_edit_form'] = $list;
  $form['#variable_options'] = $options;

  // Run submit callback for variables in form.
  $form['#submit'][] = 'variable_form_submit_callback';
  return $form;
}