RESOLVED FIXED 12417
REGRESSION: "Are you sure you want to send a form again?" sheet is displayed twice when resubmitting a form with a modified file
https://bugs.webkit.org/show_bug.cgi?id=12417
Summary REGRESSION: "Are you sure you want to send a form again?" sheet is displayed ...
David Kilzer (:ddkilzer)
Reported 2007-01-26 10:15:54 PST
Summary: When reloading a page that was the result of a form submission with a file upload(?), the "Are you sure you want to send a form again?" sheet is displayed twice (and must be confirmed twice) before the form is resubmitted. I suppose this could be considered a dummy-check security feature, but it's also kind of annoying and a regression from shipping Safari. Steps to reproduce: 1. Open Safari/WebKit. 2. Visit URL: http://validator.w3.org/#validate-by-upload 3. Select an HTML file to upload (doesn't have to pass validation). 4. Click "Check". 5. After validation page loads, click "Reload" button in Safari. Expected results: The "Are you sure you want to send a form again?" sheet should be displayed once so that clicking "Send" resubmits the form. Actual results: The "Are you sure you want to send a form again?" sheet is displayed twice, and you must click "Send" twice to resubmit the form. Regression: This is a regression from shipping Safari 2.0.4 (419.3) on Mac OS X 10.4.8 (8N1037). Tested with a locally-built debug build of WebKit r19151 with Safari 2.0.4 (419.3) on Mac OS X 10.4.8 (8N1037). Notes: Not tested on Leopard (yet).
Attachments
David Kilzer (:ddkilzer)
Comment 1 2007-01-26 11:16:07 PST
(In reply to comment #0) > Steps to reproduce: > > 1. Open Safari/WebKit. > 2. Visit URL: http://validator.w3.org/#validate-by-upload > 3. Select an HTML file to upload (doesn't have to pass validation). > 4. Click "Check". > 5. After validation page loads, click "Reload" button in Safari. I left out an important step: You must modify the file (and save it back to disk) before attempting to reload the form in order to see two sheets. 1. Open Safari/WebKit. 2. Visit URL: http://validator.w3.org/#validate-by-upload 3. Select an HTML file to upload (doesn't have to pass validation). 4. Click "Check". 5. Edit the file that was uploaded in Step 3 and resave it. 6. Click "Reload" button in Safari. Note that if you get an ASSERTION FAILED crash while trying to reproduce this, that is Bug 9920.
David Kilzer (:ddkilzer)
Comment 2 2007-01-26 12:32:37 PST
(In reply to comment #0) > Regression: > > This is a regression from shipping Safari 2.0.4 (419.3) on Mac OS X 10.4.8 > (8N1037). > > Tested with a locally-built debug build of WebKit r19151 with Safari 2.0.4 > (419.3) on Mac OS X 10.4.8 (8N1037). Note that on shipping Safari, the original file contents are resent (not the contents of the changed file) when the form is resent.
Mark Rowe (bdash)
Comment 3 2007-01-28 15:50:31 PST
Thomas Steinacher
Comment 4 2007-02-10 11:35:19 PST
When using redirects after submitting the form, the message will be sometimes displayed three times or even more (using multiple redirects). How to reproduce: 1. Create the following "form.php" on your server: <p>Hit submit and then reload the page.</p> <form action="form.php" method="post"> <input type="submit" name="submit" value="submit"> </form> 2. Load the "form.php" in your nightly WebKit and click the submit button. 3. Add the following line at the beginnig of your "form.php": <?php sleep(3); if ($_POST['submit']) header('Location: form2.php'); ?> 4. Press Apple+R in WebKit 5. The message will appear twice, and a third time after 3 seconds
David Kilzer (:ddkilzer)
Comment 5 2007-02-12 01:45:04 PST
Revision r18011 seems rather suspicious in the context of this bug. Found it while reviewing r18004:18012 per Bug 12690 Comment #12. http://trac.webkit.org/projects/webkit/changeset/18011
Anders Carlsson
Comment 6 2007-02-14 16:14:11 PST
Committed revision 19632.
Note You need to log in before you can comment on or make changes to this bug.