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: The anonymous block box around a table is not used for table percentage width</title>
5 <link rel="author" title="Microsoft" href="http://www.microsoft.com/">
6 <link rel="help" href="http://www.w3.org/TR/CSS21/tables.html#model">
7 <meta name="flags" content="">
8 <meta name="assert" content="The percentage width of table is relative to its anonymous box's containing block.">
9 <style type="text/css">
10 #div1
11 {
12 width: 400px;
13 }
14 table
15 {
16 border-spacing: 0;
17 width: 50%;
18 }
19 td
20 {
21 background: black;
22 }
23 #div2
24 {
25 background: blue;
26 height: 1em;
27 width: 200px;
28 }
29 </style>
30 </head>
31 <body>
32 <p>Test passes if boxes below are the same width.</p>
33 <div id="div1">
34 <table>
35 <tr>
36 <td>X</td>
37 </tr>
38 </table>
39 </div>
40 <div id="div2"></div>
41 </body>
42 </html>