1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2 <html>
3 <head>
4 <title>CSS Test: Z-index applied to element with 'display' set to inline</title>
5 <link rel="author" title="Microsoft" href="http://www.microsoft.com/">
6 <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#propdef-z-index">
7 <link rel="help" href="http://www.w3.org/TR/CSS21/visuren.html#z-index">
8 <meta name="flags" content="ahem">
9 <meta name="assert" content="The 'z-index' property applies to elements with a display of inline.">
10 <style type="text/css">
11 div
12 {
13 display: inline;
14 font: 20px/1em Ahem;
15 position: relative;
16 }
17 #div1
18 {
19 background: green;
20 color: green;
21 }
22 #zindex
23 {
24 background: red;
25 color: red;
26 left: -5em;
27 z-index: -1;
28 }
29 </style>
30 </head>
31 <body>
32 <p>Test passes if there is no red visible on the page.</p>
33 <div id="div1">XXXXX</div><div id="zindex">XXXXX</div>
34 </body>
35 </html>