table-caption-horizontal-alignment-001

Horizontally aligning table caption content

WeasyPrint

This browser

Assertion
Table caption content can be horizontally aligned with the 'text-align' property.

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: Horizontally aligning table caption content</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#caption-position">
 7         <meta name="flags" content="">
 8         <meta name="assert" content="Table caption content can be horizontally aligned with the 'text-align' property.">
 9         <style type="text/css">
10             caption
11             {
12                 border: 1px solid black;
13                 text-align: right;
14                 width: 200px;
15             }
16         </style>
17     </head>
18     <body>
19         <p>Test passes if the "Filler Text" below is on the right side of the box.</p>
20         <table>
21             <caption>Filler Text</caption>
22             <tr>
23                 <td></td>
24             </tr>
25         </table>
26     </body>
27 </html>