Jquery Datatables Multiple Header Issue -
when set datatables have multiple header rows, swidth parameters have been set ignored. there way of telling datatables header should second row rather first? searched , datatables dot net docs , couldn't find anything.
in picture, first column (year) should wider others. works fine when there 1 header row, when there 2 header rows width specified (using swidth) ignored.
this works me on safari, firefox, , chrome: http://jsfiddle.net/zbn3j/
<table id=test> <thead> <tr><th colspan=4>cars</th></tr> <tr><th>year</th><th>unit</th><th>time</th><th>status</th></tr> </thead> <tbody> <tr><td>r1,c1</td><td>r1,c2</td><td>r1,c3</td><td>r1,c4</td></tr> <tr><td>r2,c1</td><td>r2,c2</td><td>r2,c3</td><td>r2,c4</td></tr> </tbody> </table>
with call datatable:
$('#test').datatable( { "aocolumndefs": [{ "swidth": "200px", "atargets": [ 0 ] }] });
how differ code or experience?
Comments
Post a Comment