This example shows Scroller operating with FixedColumns. FixedColumns has the ability to "freeze" columns and the left and right of a scrolling table in place. Initialisation is exactly the same as normal and all of the standard options are available for both FixedColumns and Scroller. They will automatically detect if they are being used together.
You may need to resize your browser window to force the table to scroll horizontally with this example!
The Javascript shown below is used to initialise the table shown in this example:
1 2 3 4 5 6 7 8 9 10 11 12 | $(document).ready( function () { var table = $( '#example' ).DataTable( { ajax: "../data/2500.txt" , deferRender: true , scrollY: 200, scrollX: true , scrollCollapse: true , scroller: true } ); new $.fn.dataTable.FixedColumns( table ); } ); |
In addition to the above code, the following Javascript library files are loaded for use in this example: