Closed Bug 58995 Opened 25 years ago Closed 23 years ago

window.opener.formName.submit() submits the wrong form[form sub]

Categories

(Core :: DOM: Core & HTML, defect, P3)

x86
Windows 2000
defect

Tracking

()

VERIFIED WORKSFORME
Future

People

(Reporter: testing, Assigned: alexsavulov)

References

()

Details

Scenario: Page 1 opens page 2. Page 1 has foobarForm, so does page 2. Page 2 calls window.opener.foobarForm.submit() from a onclick handler, Moz submits page 2's form instead of page 1's. This happens even if the form names for page 1 and 2 are different. Bug also exists in Netscape 4x. Works like a charm in IE5x, of course. The cross-browser workaround (IE, NS4x, Moz) I'm using right now for this is to add "document." in front of the form name. so: window.opener.document.formName.submit() submits the proper form (the form belonging to the opener). Last tested on Moz 20001102. Suspect to be ALL platform bug, people on non-Win32 platforms please test.
figtree: thank you for volunteering to attach a testcase or entering a testcase url.
Keywords: makingtest
reassigning
Assignee: rods → pollmann
Setting milestone to future
Target Milestone: --- → Future
Reporter: I'd like to test this but I need a testcase
Bulk reassigning Eric Pollmann's remaining form submission bugs to Alex.
Assignee: pollmann → alexsavulov
Summary: window.opener.formName.submit() submits the wrong form → window.opener.formName.submit() submits the wrong form[form sub]
window.opener.foobarForm of course does not exist but window.opener.document.foobarForm.submit() does the right thing. Witness the URL: page1.html opens a window with page2.html, which submits page1.html, which tries to go to nowhere.html. WFM Linux 2002011808, please reopen if this is still happening.
Status: NEW → RESOLVED
Closed: 23 years ago
Resolution: --- → WORKSFORME
verifying on linux 2002-02-25-09-trunk and windows 2000 build 2002-02-22-03-trunk
Status: RESOLVED → VERIFIED
Blocks: 558996
No longer blocks: 558996
Component: HTML: Form Submission → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.