function _google_tag_variable_states in GoogleTagManager 7.2
Same name and namespace in other branches
- 7 includes/variable.inc \_google_tag_variable_states()
Returns states array for a form element.
Parameters
string $variable: The name of the form element.
Return value
array The states array.
1 call to _google_tag_variable_states()
- _google_tag_variable_info_advanced in includes/
variable.inc - Implements hook_variable_info().
File
- includes/
variable.inc, line 470 - Contains the variable definitions.
Code
function _google_tag_variable_states($variable) {
return array(
'required' => array(
':input[name="' . $variable . '"]' => array(
'checked' => TRUE,
),
),
'invisible' => array(
':input[name="' . $variable . '"]' => array(
'checked' => FALSE,
),
),
);
}