function form_test_limit_validation_errors_form_partial_submit in Drupal 7
Form submit handler for the partial validation submit button.
1 string reference to 'form_test_limit_validation_errors_form_partial_submit'
- form_test_limit_validation_errors_form in modules/
simpletest/ tests/ form_test.module - Builds a simple form with a button triggering partial validation.
File
- modules/
simpletest/ tests/ form_test.module, line 560 - Helper module for the form API tests.
Code
function form_test_limit_validation_errors_form_partial_submit($form, $form_state) {
// The title has not been validated, thus its value - in case of the test case
// an empty string - may not be set.
if (!isset($form_state['values']['title']) && isset($form_state['values']['test'])) {
drupal_set_message('Only validated values appear in the form values.');
}
}