Column headers shrinking when using scrolling with jquery tabs.
Column headers shrinking when using scrolling with jquery tabs.
blockheadsilver
Posts: 12Questions: 0Answers: 0
$(document).ready(function() {
$("#tabs").tabs( {
"show": function(event, ui) {
var table = $.fn.dataTable.fnTables(true);
if ( table.length > 0 ) {
$(table).dataTable().fnAdjustColumnSizing();
}
}
} );
$('table.display').dataTable( {
"sScrollY": "200px",
"bScrollCollapse": true,
"bPaginate": false,
"bJQueryUI": true,
"aoColumnDefs": [
{ "sWidth": "10%", "aTargets": [ -1 ] }
]
} );
} );
Have used the above code for my datatable as you have mentioned this as the fix in one of the discussions but i am getting and error on javascript side saying :TypeError: $.fn.dataTable.fnTables is not a function.
I have imported the datatables.js jquery.js everything thats needed.
Please suggest.
Thanks.
$("#tabs").tabs( {
"show": function(event, ui) {
var table = $.fn.dataTable.fnTables(true);
if ( table.length > 0 ) {
$(table).dataTable().fnAdjustColumnSizing();
}
}
} );
$('table.display').dataTable( {
"sScrollY": "200px",
"bScrollCollapse": true,
"bPaginate": false,
"bJQueryUI": true,
"aoColumnDefs": [
{ "sWidth": "10%", "aTargets": [ -1 ] }
]
} );
} );
Have used the above code for my datatable as you have mentioned this as the fix in one of the discussions but i am getting and error on javascript side saying :TypeError: $.fn.dataTable.fnTables is not a function.
I have imported the datatables.js jquery.js everything thats needed.
Please suggest.
Thanks.
This discussion has been closed.