Quantcast
Channel: Recent Discussions — DataTables forums
Viewing all articles
Browse latest Browse all 82136

sScrollY creates double <thead> and cols are misaligned

$
0
0
I use this code to generate my table
$('#myTable').dataTable( {
  "bPaginate": false,
  "bLengthChange": false,
  "bFilter": false,
  "bSort": false,
  "bInfo": false,
  "bAutoWidth": false,
  "bDestroy": true,
  "sDom": 'T<"clear">t',
  "sScrollY": "500",
  "oTableTools": {
  "sSwfPath": base_url+"js/swf/copy_csv_xls_pdf.swf"
 }
} );
The problem is that the generated <th>s are of different sizes respect to the corresponding <td>s
looking at the source code I've noticed that there are two divs, one is "dataTables_scrollHeadInner" and it contains a table which contains my original <thead> and <th>s, the other is dataTables_scrollBody and it contains a table with an empty <thead> with right size <th>s and a <tbody> with all my data.
I'm using the last version of dataTables (1.9.4).

Here a snapshot http://www.makerfaire.it/etc/datatables_error.png

Any hint?
thank you in advance

Viewing all articles
Browse latest Browse all 82136

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>