I have a table that has a large number of line and columns. But I would like to have the header fixed and the first column fixed. Here is a picture of what I need.
Only the pink part must scroll horizontally and vertically but the others must stay visible during the scrolling. My table is in a div. First, should I use one table or four (the blue one, the red one, the green one and the pink one) ?
I have written this fiddle:
I tried to fix the header first but I wasn't a success
#container thead {
position: fixed;
top: 0;
}
and something like this to select and fix the first column
#container tbody tr td:first-child {
position: fixed;
left: 0;
}
but it's not fixing about the div that wrap my table. Maybe I will need some jQuery or JavaScript?
If anyone could help.