2 datatables on 1 page & dataTables_filter
2 datatables on 1 page & dataTables_filter
marcelnl1
Posts: 1Questions: 0Answers: 0
Using two datatables on one page is working absolutely flawless, however I am experiencing issues with the dataTables_filter class which is used for the searchbox.
I can without a problem restyle this box using the dataTables_filter class, but this will restyle the box for both tables, but i need to use different styles for each tables.
Does anyone have a clue as to how to do this?
I can without a problem restyle this box using the dataTables_filter class, but this will restyle the box for both tables, but i need to use different styles for each tables.
Does anyone have a clue as to how to do this?
This discussion has been closed.
Replies
DataTables automatically adds a DIV wrapper around the table with an ID of {tableid_wrapper}. So if your table has an ID you can do:
[code]
#table1_wrapper div.dataTables_filter {...}
#table2_wrapper div.dataTables_filter {...}
[/code]
Allan