blob: e771379f63008c0b6297442c0c9162f737c19a77 [file] [log] [blame]
ap08a32002006-10-01 08:35:29 +00001<html>
2<head>
3<script>
4function test() {
5 if (document.URL.indexOf('?') == -1) {
6
rniwa@webkit.orgea3cf922012-06-22 06:52:33 +00007 if (window.testRunner) {
8 testRunner.dumpAsText();
9 testRunner.waitUntilDone();
ap08a32002006-10-01 08:35:29 +000010 }
11
12 document.write("<html><body>" +
13 "<form name='f' action='?' method='post'>" +
14 "<input type=submit></form><scri" +
15 "pt>document.f.submit();</scri" +
16 "pt></body></html>");
17 } else {
18 document.getElementById("result").innerHTML="SUCCESS";
rniwa@webkit.orgea3cf922012-06-22 06:52:33 +000019 if (window.testRunner)
20 testRunner.notifyDone();
ap08a32002006-10-01 08:35:29 +000021 }
22
23}
24</script>
25</head>
26<body onload="test()">
eric@webkit.orgb5c79932009-09-29 19:15:13 +000027<p>Test for <a href="https://bugs.webkit.org/show_bug.cgi?id=4372">bug 4372</a>:
ap08a32002006-10-01 08:35:29 +000028JavaScript document.write page form does not submit in Safari if document.close is not called.</p>
29<p id=result>FAILURE</p>
30</body>
31</html>