Answers for "datatable change default page size"

4

datatables change width of columns

$('#example').dataTable( {
  "autoWidth": false, // might need this
  "columns": [
    { "width": "20%" },
    null, // automatically calculates
    null  // remaining width
  ]
} );
Posted by: Guest on September-08-2020
0

datatable change default page size

Javascript
1
2
3
$('#example').dataTable( {
  "pageLength": 50
} );
Posted by: Guest on October-17-2021
0

Datatable Change page size for pdf

buttons: [
            'csv', 'excel',
            {
                extend: 'pdfHtml5',
                pageSize: 'A3',
                exportOptions: {
                    columns:':visible',
                    rows: ':visible'
                }
            },
        ],
Posted by: Guest on October-07-2021

Browse Popular Code Answers by Language