1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
<html>
<body>
<script>
i = 0;
windowArgs = "top=100, left=100, height=200, width=200";
windowName = "";
w = window.open("", windowName + i++, windowArgs);
w.document.write("PASS: document.write after window.open(\"\", ...) worked.");
w.document.close();
w = window.open("", windowName + i++, windowArgs);
w.document.open();
w.document.write("PASS: document.write after window.open(\"\", ...) worked.");
w.document.close();
w = window.open("about:blank", windowName + i++, windowArgs);
w.document.write("PASS: document.write after window.open(\"about:blank\", ...) worked.");
w.document.close();
w = window.open("about:blank", windowName + i++, windowArgs);
w.document.open();
w.document.write("PASS: document.write after window.open(\"about:blank\", ...) worked.");
w.document.close();
w = window.open("resources/write-after-open-popup.html", windowName + i++, windowArgs);
w.document.write("PASS: document.write after window.open(\"resources/write-after-open-popup.html\", ...) worked.");
w.document.close();
w = window.open("resources/write-after-open-popup.html", windowName + i++, windowArgs);
w.document.open();
w.document.write("PASS: document.write after window.open(\"resources/write-after-open-popup.html\", ...) worked.");
w.document.close();
</script>
<p>This test checks for regression against: <rdar://problem/3461547> can't use document.writeln() on windows opened via window.open("about:blank") in same function. </p>
<p>On success, 6 windows will open, one on top of the other, each containing a PASS message.</p>
</body>
</html>
|