2007-07-12 Mitz Pettel <mitz@webkit.org>
[WebKit-https.git] / LayoutTests / fast / history / resources / history_reload_window.html
1 <html>
2     <head>
3         <script>
4         function test() {
5             var tempConsole = document.getElementById('console');
6             var console = window.opener.document.getElementById('console');
7             if (window.opener.i == 0) {
8                 tempConsole.innerHTML = 'Test Failed';
9                 console.innerHTML = tempConsole.innerHTML;
10                 window.opener.i = window.opener.i + 1;
11                 history.go(0);
12             } else {
13                 console.innerHTML = tempConsole.innerHTML;
14                 window.close();
15             }
16         }
17
18         function closed()
19         {
20             if (window.layoutTestController)
21                 opener.setTimeout("layoutTestController.notifyDone()", 0);
22         }
23         </script>
24     </head>
25     <body onload="test()" onunload="closed()">
26         <div id="console">Test Passed</div>
27     </body>
28 </html>