Clone of table header doesn't inherit width when table is bigger than the window
I am using this script to make my table headers stick to the top of the page when scrolling through the table: http://cmcqueen1975.bitbucket.org/htmlFloatingTableHeader/tables.html
The problem is, when the table exceeds the window size, the table headers are still crammed in to 100% of the screen width. Then the headers don't line up with the cells th开发者_高级运维ey represent. This can be seen in this fiddle:
http://jsfiddle.net/UDNNr/
The css-width of the cloned
<tr/>
doesn't match the sum of the width of the cells inside, you don't need to set the width of the<tr/>
What you need is to set the table-layout-style of the table to "fixed"
精彩评论