<html> | |
<head> | |
<script> | |
function test() { | |
if (document.URL.indexOf('?') == -1) { | |
if (window.testRunner) { | |
testRunner.dumpAsText(); | |
testRunner.waitUntilDone(); | |
} | |
document.write("<html><body>" + | |
"<form name='f' action='?' method='post'>" + | |
"<input type=submit></form><scri" + | |
"pt>document.f.submit();</scri" + | |
"pt></body></html>"); | |
} else { | |
document.getElementById("result").innerHTML="SUCCESS"; | |
if (window.testRunner) | |
testRunner.notifyDone(); | |
} | |
} | |
</script> | |
</head> | |
<body onload="test()"> | |
<p>Test for <a href="https://bugs.webkit.org/show_bug.cgi?id=4372">bug 4372</a>: | |
JavaScript document.write page form does not submit in Safari if document.close is not called.</p> | |
<p id=result>FAILURE</p> | |
</body> | |
</html> |