Files
servo/tests/wpt/css-tests/css21_dev/html4/table-columns-example-002.htm

54 lines
1.6 KiB
HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<title>CSS Test: Table columns - Assigning a background to a column</title>
<link rel="author" title="W3C" href="http://www.w3c.org">
<link rel="author" title="Microsoft" href="http://www.microsoft.com/">
<link rel="help" href="http://www.w3.org/TR/CSS21/tables.html#columns">
<meta name="flags" content="">
<meta name="assert" content="A specific column class can be selected for a blue background (example from section 17.3).">
<style type="text/css">
table
{
border-collapse: collapse;
}
col
{
border-style: solid;
}
col.totals
{
background: blue;
}
td
{
border: 1px solid black;
height: 2em;
width: 2em;
}
</style>
</head>
<body>
<p>Test passes if the middle column of the three-by-three grid is blue.</p>
<table>
<col>
<col class="totals">
<col>
<tr>
<td></td>
<td></td>
<td></td>
</tr>
<tr>
<td></td>
<td></td>
<td></td>
</tr>
<tr>
<td></td>
<td></td>
<td></td>
</tr>
</table>
</body>
</html>