Need help in removing sort arrows (asc and desc) on data tables header row, then when the user click the header column an ascending arrow will appear and of course data will be sorted in asc order
标签:
datatables
相关问题
- jQuery DataTable - Search a column of dropdowns
- Uncaught TypeError: undefined is not a function fo
- Avoid Rendering “No Data Available in the table” i
- datatables initialize table after button click (aj
- Jquery datatable Sort not working for Date Column?
相关文章
- DataTable : How to hide table header?
- Selecting all visible rows after a search using
- How to add a class to a new row in a jquery datata
- jQuery Datatables - how to programatically sort by
- Loading DataTable using ajax
- Data Tables Get iDataRow in mRender
- DataTables warning: table id=dataTables - Ajax err
- How to search for an exact string in a jQuery Data
"aoColumnDefs": [ { "bSortable": false, "aTargets": [ 1, 3 ] } ]
To remove sort arrows from the second and the fourth columns.
ref -> http://wordpress.org/support/topic/plugin-wp-table-reloaded-removing-the-updown-sorting-arrows-on-specific-columns
HOW TO REMOVE DATATABLES GLYPHCONS / ICONS !!
Use this following code on your css file : if you see the column glyph-cons on Table header use this !!
if you see the glyph-cons on Table data use this !!
in short change "this" part, where the class="sorting_desc/asc" situated.
Within dataTables.Bootstrap.css are three classes that add these sort images. They are sorting, sorting_asc, and sorting_desc. During the DataTable initialization disable sorting as first stated by "satej kumar sahu" via the bSortable : false. Then do a removeClass for the header, my header had an id="division". Then create a click event for the header, same id, to do a another removeClass to preserve any other functionality, in my case to preserve the column dropdown via columnFilter. Review attached code.
what I got from your question is that you want to remove initial sort from the table and only sort when the user clicks on a column header. you can do that using the following code:
http://datatables.net/ref#aaSorting