Row to hide a row in dataTable ?
Row to hide a row in dataTable ?
arunnuvac
Posts: 1Questions: 1Answers: 0
I need to add some custom filtering to the table. which include dynamically hiding showing of some rows in the table. I have constructed my table using DataTable. so i need a method to hide particular row from "row" object. So anyone can help me with it?
This discussion has been closed.
Answers
use $.fn.dataTable.ext.search.push. Return "true" for rows you want to show and "false" for rows you want to hide.
It will be run for all of your datatables on your page. You need to be careful if you have mutliple data tables on the same page. For that reason I check for "undefined" in the example below.
This example works with multiple tables on the same page: