How to fixed datatable header on top when scroll

datatables fixed header bootstrap 4
datatables fixed header bootstrap 4
datatables fixed header bootstrap 4

Hello guy’s most of designer facing this problem how to fixed datatable header on scroll, here i will tell you how to fixed Bootstrap datatable header.

Fixed Bootstrap datatable header top on scroll is very easy, in previous article i have told that how to create bootstrap datatable just donload that file and add some javascript.

 <script>
	$(document).ready(function() {
    $('#example').DataTable( {
        "scrollY": 200,
        "scrollX": true
    } );
} );
	
</script>

After adding this javascript code you Bootstrap datatable header will fixed on top when you scroll.

Leave a Reply

avatar
  Subscribe  
Notify of