HTML <col> Tag
<table>
<colgroup>
<col style="background:white;">
<col span="2" style="background:#F7F0D3;">
<col style="background:#F9D74E;">
</colgroup>
<tr>
<th>Header 1</th>
<th>Header 2</th>
<th>Header 3</th>
<th>Header 4</th>
</tr>
<tr>
<td>Cell</td>
<td>Cell</td>
<td>Cell</td>
<td>Cell</td>
</tr>
<tr>
<td>Cell</td>
<td>Cell</td>
<td>Cell</td>
<td>Cell</td>
</tr>
</table>
The <col>
element represents one or more columns within a <colgroup>
element.
The <col>
element is useful for applying different styles across one or more (but not all) columns within a column group. If you need to apply the same styles across a whole column group, just apply those styles to the <colgroup>
element.