I have seen this major topic how do I create an HTML table with fixed/frozen left column and scrollable body? and I tried to adapt but I constantly fail due to the fact that I use the thead
and tbody
tags and none of that examples do.
The thead
is composed by the days of the month, and the tbody
has the employers names.
<table>
<thead>
<tr>
<th></th>
<th>01 July</th>
<th>02 July</th>
</tr>
</thead>
<tbody>
<tr>
<td>Employee 1</td>
<td></td>
<td></td>
</tr>
<tr>
<td>Employee 2</td>
<td></td>
<td></td>
</tr>
</tbody>
</table>
I need the td
that contains the employers names to be fixed while scrolling horizontally.