Answers for "order datatable"

0

orderable false in datatable

$('#example').DataTable( {
  columnDefs: [
    { orderable: false, targets: 0 }
  ]
} );

reference: 
https://datatables.net/reference/option/columns.orderable
Posted by: Guest on January-29-2021
1

order datatable

$(document).ready(function() {
    $('#example').DataTable( {
        "order": [[ 3, "desc" ]]
    } );
} );
Posted by: Guest on May-04-2021
1

sort datatable c#

Datatable.DefaultView.Sort = "Preferance ASC";
Posted by: Guest on February-19-2020
0

datatable get order column

var table = $('#example').DataTable();

var order = table.order();
alert( 'Table is ordered by column: ' + order[0][0] + ', direction:' + order[0][1]);

var title = table.column(order[0][0]).header();
alert( 'Ordering column title: ' + $(title).html() );
Posted by: Guest on February-28-2020

Browse Popular Code Answers by Language