I have the following table declaration:
<table width="80%" style="border: 1px solid black; border-collapse: collapse; table-layout: fixed;">
<tbody>
<tr>
<td style="border: 1px solid black; border-collapse: collapse;" width="80%" colspan="2" >This is a very long first line here, taking the entire width of the table</td>
</tr>
<tr>
<td style="border: 1px solid black;" width="10%">Comment</td>
<td style="border: 1px solid black;" width="80%">My text on the comment cell</td>
</tr>
</tbody>
</table>
I don't understand why my second column is as wide as the first one. I thought that by specifying the table-layout: fixed; property for the table, and setting the columns widths, I would obtain what I wanted, which was:
- A first row with only one cell of a width which would be 100% of the table width
- A second row with a small first cell, and a second wide second cell