Can we exclude sorting option from some of the columns
Can we exclude sorting option from some of the columns

Hi,
Can we exclude sorting option from some of the columns?
My requirement is: I have some column headers like Action or checkall (checkbox) which should not be sortable. Can somebody help me, how can I do this?
Thanks
Can we exclude sorting option from some of the columns?
My requirement is: I have some column headers like Action or checkall (checkbox) which should not be sortable. Can somebody help me, how can I do this?
Thanks
This discussion has been closed.
Replies
Look under bSort here: http://datatables.net/usage/features (it mentions bSortable)
Here is an example:
[code]
oTable.dataTables({
...
"aoColumns":[{"sTitle":"Action", "bSortable":false},{"sTitle":"checkall", "bSortable":false},{"sTitle":"someColumn"}],
...
});
[/code]
Here, Action and checkall will not be sortable, but someColumn will be.
Hope this helps.
"aoColumns": [ { "bSortable": false },
{ "bSortable": true },
{ "bSortable": true },
{ "bSortable": true },
{ "bSortable": true },
{ "bSortable": true },
{ "bSortable": true },
{ "bSortable": false },
{ "bSortable": false }
]
Here are some more options you can use for your columns: http://datatables.net/usage/columns .(It also has more stuff on bSortable)
Glad you got it working.