Closed
Bug 431445
Opened 17 years ago
Closed 3 years ago
Can't call form.submit() inside document.onunload handler
Categories
(Core :: DOM: Core & HTML, defect, P5)
Tracking
()
RESOLVED
DUPLICATE
of bug 356923
People
(Reporter: brett, Unassigned)
References
()
Details
Attachments
(1 file)
(deleted),
text/html
|
Details |
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.14) Gecko/20080404 Firefox/2.0.0.14
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.14) Gecko/20080404 Firefox/2.0.0.14
If you have a document.unload() handler, which calls into the current page's dom and tries to submit a form, the javascript runs with no errors, but the form never gets submitted.
In the example link above, the form should submit when clicking the url 'Exit Page'.
Reproducible: Always
Steps to Reproduce:
1. Create a page with a form on it
2. Create a document.unload handler
3. inside the handler, call document.forms[0].submit()
4. Note forms[0] never gets submitted.
Actual Results:
Form wasn't submitted
Expected Results:
The form should either submit, or an explicit javascript error should be raised.
Comment 1•17 years ago
|
||
Related to bug 356923?
Summary: Can't call form events inside document.onunload handler → Can't call form.submit() inside document.onunload handler
Reporter | ||
Comment 2•17 years ago
|
||
Added the test case as an attachement. Click the 'Exit Page' link. Note the 'kavi_form' isn't submitted.
Updated•17 years ago
|
Component: General → DOM
Product: Firefox → Core
QA Contact: general → general
Comment 4•6 years ago
|
||
https://bugzilla.mozilla.org/show_bug.cgi?id=1472046
Move all DOM bugs that haven’t been updated in more than 3 years and has no one currently assigned to P5.
If you have questions, please contact :mdaly.
Priority: -- → P5
Assignee | ||
Updated•6 years ago
|
Component: DOM → DOM: Core & HTML
Updated•3 years ago
|
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•