index.html 1.4 KB
Newer Older
1
2
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
3
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
4
5
6
    <head>
        <style type="text/css">
            body { margin: 0; font-size: 2em; }
7
8
            h1 { text-align: center; color: red; }
            h1 + h1 { color: green; }
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
            h1:last-child { color: blue; }
            #quit { background-color: gray; color: white; font-weight: bold; display: block; text-align: right; }
        </style>
        <script type="text/javascript">
            var counter = 0;
            function toggleElement()
            {
                var elements = document.getElementsByTagName('h1');
                for (var i = 0; i < elements.length; ++i)
                    elements[i].style.display = (counter % elements.length) == i ? '' : 'none';
                counter++;
                setTimeout('toggleElement()', 1000);
            }
            window.onload = function()
            {
                document.getElementById("quit").onmousedown = function()
                {
                    Qt.quit();
                };
                toggleElement();
            }
        </script>
    </head>
    <body>
        <a id="quit">X</a>
        <h1>Hello</h1>
        <h1>Html5</h1>
        <h1>World</h1>
    </body>
</html>