≡
×
Plus
Manual
Examples
Reference
Download
Blog
Community
Support
oColumnFilterWidgets on multiple tables - aiExclude issue
oColumnFilterWidgets on multiple tables - aiExclude issue
McCoRmIcK
Posts: 2
Questions: 0
Answers: 0
February 2013
edited February 2013
in
Plug-ins
hello
i try to use the oColumnFilterWidgets plugin on multiple tables. everything works fine, but when i add aiExclude it will only affect the first table.
here is an example http://dpl.sportwheels.de/liga/test.html
Replies
essexsteph
Posts: 57
Questions: 0
Answers: 0
February 2013
I think it's because you're initialising both tables together. Try giving each table an id, e.g.
[code]
...
...
[/code]
... and then initialising each table separately by id
[code]
var oTable1 = $('#table1').dataTable( {
"sDom": 'W<"clear">t',
"oColumnFilterWidgets": {
"aiExclude": [ 1 ]
}
var oTable2 = $('#table2').dataTable( {
"sDom": 'W<"clear">t',
"oColumnFilterWidgets": {
"aiExclude": [ 1 ]
}
[/code]
Obviously you'll have to change the rest of your javascript to handle each table separately.
Steph
McCoRmIcK
Posts: 2
Questions: 0
Answers: 0
February 2013
this will work, but my example is just a small piece of my datatables code.
would be fine to have a better solution
This discussion has been closed.
Replies
[code]
...
...
[/code]
... and then initialising each table separately by id
[code]
var oTable1 = $('#table1').dataTable( {
"sDom": 'W<"clear">t',
"oColumnFilterWidgets": {
"aiExclude": [ 1 ]
}
var oTable2 = $('#table2').dataTable( {
"sDom": 'W<"clear">t',
"oColumnFilterWidgets": {
"aiExclude": [ 1 ]
}
[/code]
Obviously you'll have to change the rest of your javascript to handle each table separately.
Steph
would be fine to have a better solution