Index: includes/form.inc =================================================================== RCS file: /cvs/drupal/drupal/includes/form.inc,v retrieving revision 1.265.2.23 diff -u -p -r1.265.2.23 form.inc --- includes/form.inc 27 Apr 2009 14:41:11 -0000 1.265.2.23 +++ includes/form.inc 26 May 2009 20:01:47 -0000 @@ -294,6 +294,10 @@ function drupal_execute($form_id, &$form $args = func_get_args(); $form = call_user_func_array('drupal_retrieve_form', $args); $form['#post'] = $form_state['values']; + // Reset form validation. + // If form validation fails once it fails for all subsequent elements! + $form_state['must_validate'] = TRUE; + form_set_error(NULL, '', TRUE); // reset all form errors drupal_prepare_form($form_id, $form, $form_state); drupal_process_form($form_id, $form, $form_state); } @@ -561,12 +565,6 @@ function drupal_prepare_form($form_id, & * not be repeated in the submission step. */ function drupal_validate_form($form_id, $form, &$form_state) { - static $validated_forms = array(); - - if (isset($validated_forms[$form_id])) { - return; - } - // If the session token was set by drupal_prepare_form(), ensure that it // matches the current user's session. if (isset($form['#token'])) { @@ -577,7 +575,6 @@ function drupal_validate_form($form_id, } _form_validate($form, $form_state, $form_id); - $validated_forms[$form_id] = TRUE; } /**