summaryrefslogtreecommitdiff
path: root/includes
diff options
context:
space:
mode:
authorGábor Hojtsy <gabor@hojtsy.hu>2008-01-25 16:24:48 +0000
committerGábor Hojtsy <gabor@hojtsy.hu>2008-01-25 16:24:48 +0000
commitea79c66c033fc835fc404d6ca751189414ae734e (patch)
tree944999146240fc920ebbe4d509cfd13085404606 /includes
parent85cae0d01ab9eebc2d9464e2bf0e63ed63ae9a13 (diff)
downloadbrdo-ea79c66c033fc835fc404d6ca751189414ae734e.tar.gz
brdo-ea79c66c033fc835fc404d6ca751189414ae734e.tar.bz2
#194327 by dvessel, David_Rothstein, catch, theborg: IE form submission button correction was buggy
Diffstat (limited to 'includes')
-rw-r--r--includes/form.inc11
1 files changed, 8 insertions, 3 deletions
diff --git a/includes/form.inc b/includes/form.inc
index 6d562e577..9a28ddf73 100644
--- a/includes/form.inc
+++ b/includes/form.inc
@@ -907,9 +907,14 @@ function form_builder($form_id, $form, &$form_state) {
// Now that we've processed everything, we can go back to handle the funky
// Internet Explorer button-click scenario.
_form_builder_ie_cleanup($form, $form_state);
-
- // After handling the special IE case, we no longer need the buttons collection.
- unset($form_state['buttons']);
+
+ // We shoud keep the buttons array until the IE clean up function
+ // has recognized the submit button so the form has been marked
+ // as submitted. If we already know which button was submitted,
+ // we don't need the array.
+ if (!empty($form_state['submitted'])) {
+ unset($form_state['buttons']);
+ }
// If some callback set #cache, we need to flip a static flag so later it
// can be found.