Closed Bug 68814 Opened 25 years ago Closed 25 years ago

form posted to new window when domain truncated

Categories

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

x86
Windows NT
defect
Not set
normal

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: asreddy_74, Assigned: pollmann)

References

Details

From Bugzilla Helper: User-Agent: Mozilla/4.0 (compatible; MSIE 5.0; Windows NT; DigExt) BuildID: Mozilla/5.0 (Windows; U; WinNT4.0; en-US; m18) Gecko/20010131 When a form in a page has target an iframe and document domain is truncated iframe lauched in new window when form is submited. Problem can be reproduced on tomcat and iis webservers but not on apache where it works allright Reproducible: Always Steps to Reproduce: create file 1 <HTML> <HEAD> <SCRIPT> var lsOrigin = document.domain; var liFirstDot = lsOrigin.indexOf( "." ); document.domain = lsOrigin.substring( liFirstDot + 1 ); document.write( document.domain ); </SCRIPT> </HEAD> <BODY> <FORM target="frm1" method="post" action="http://www.mozilla.org"> <input type="submit" value="submit"> </FORM> <IFRAME name="frm1" width="100%" height="200" src="http://myserver.com/myfile2.html"></IFRAME> </P> </BODY> </HTML> Change source of iframe (http://myserver.com/myfile2.html) to location of file2 on your server file 2 <HTML> <HEAD> <script> var lsOrigin = document.domain; var liFirstDot = lsOrigin.indexOf( "." ); document.domain = lsOrigin.substring( liFirstDot + 1 ); </script> </HEAD> <BODY> <SCRIPT> document.write( document.domain + "<BR>" ); </SCRIPT> </BODY> </HTML> Actual Results: In tomcat and iis webserver (on NT) form submitted in new window and in apache form submitted to iframe in same window Expected Results: form should be submitted in the same window The idea is to look if page is scriptable and when not open a new window (after origin check)
*** Bug 68815 has been marked as a duplicate of this bug. ***
*** Bug 68816 has been marked as a duplicate of this bug. ***
reassigning
Assignee: rods → pollmann
changing component
Component: HTML Form Controls → Form Submission
Keywords: qawanted
I am changing the status of this bug to blocker as this is a showstopper for us.
Severity: major → blocker
I can not reproduce this problem. Reporter, can you post a public URL that we can reproduce this at? (Set up your testcase on an Apache server and it worked as it should, but this is as you describe)
FWIW, an apache server with this testcase working is here: http://302easyst.net/~pollmann/bugs/spoof/8/index.html
WORKSFORME Platform: PC OS: Windows 98 Mozilla Build: 2001032804 Marking as such.
Severity: blocker → normal
Status: UNCONFIRMED → RESOLVED
Closed: 25 years ago
Resolution: --- → WORKSFORME
Keywords: qawanted
Component: HTML: Form Submission → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.