html-attribute-013

Attribute 'valign' vs. CSS 'vertical-align' specificity

WeasyPrint

This browser

Assertion
Attribute 'valign' has a specificity of zero and is overridden by CSS.

Source

 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: Attribute 'valign' vs. CSS 'vertical-align' specificity</title>
 5         <link rel="author" title="Microsoft" href="http://www.microsoft.com/">
 6         <link rel="help" href="http://www.w3.org/TR/CSS21/cascade.html#preshint">
 7         <meta name="flags" content="">
 8         <meta name="assert" content="Attribute 'valign' has a specificity of zero and is overridden by CSS.">
 9         <style type="text/css">
10             table
11             {
12                 border: 1px solid;
13                 border-spacing: 0;
14                 height: 200px;
15                 width: 100%;
16             }
17             *
18             {
19                 padding: 0;
20                 vertical-align: top;
21             }
22         </style>
23     </head>
24     <body>
25         <p>Test passes if the "Filler Text" is at the top-left corner of the box below.</p>
26         <table>
27             <tr>
28                 <td valign="bottom">Filler Text</td>
29             </tr>
30         </table>
31     </body>
32 </html>