function views_handler_filter_boolean_operator::value_validate in Views (for Drupal 7) 6.2
Same name and namespace in other branches
- 6.3 handlers/views_handler_filter_boolean_operator.inc \views_handler_filter_boolean_operator::value_validate()
- 7.3 handlers/views_handler_filter_boolean_operator.inc \views_handler_filter_boolean_operator::value_validate()
Validate the options form.
Overrides views_handler_filter::value_validate
File
- handlers/
views_handler_filter_boolean_operator.inc, line 111
Class
- views_handler_filter_boolean_operator
- Simple filter to handle matching of boolean values
Code
function value_validate($form, &$form_state) {
if ($form_state['values']['options']['value'] == 'All' && empty($form_state['values']['options']['expose']['optional'])) {
form_set_error('value', t('You must select a value unless this is an optional exposed filter.'));
}
}