johnamos Posts: 2Questions: 1Answers: 0
In the example on datatables.net the column headers do not align with the data in the table (http://imgur.com/fyo6XOB). I tried to change this with CSS but I can't get rid of that extra space. I searched this forum but I can't find anyone else complaining about it.
This discussion has been closed.
What did you do?
We observed a similar issue in our implementation when we were using fixed headers. After searching, filtering out changing Pages this issue is resolved.
To solve our problem we updated the header table width equal to the main datatable width in initComplete.
I fixed this with the following CSS:
Notice the padding on the left (5px) and right (18px) are the same for header and body so that they will align. The 18px padding on the right is required to accommodate the triangular sort indicators. This CSS also adds borders to separate the columns. The result looks better: