"AND" Filtering by Drop-Down and Filter input box
"AND" Filtering by Drop-Down and Filter input box
Hi,
First let me say that Datatables is awesome, and an amazing functional enhancement for our product.
We have the normal filtering using the input box, and we have implemented filtering using a drop-down list. Both work fine - on their own. But, we want them to work together, so that if someone has filtered using the input box, and then we call fnFilter when the dropdown changes, we filter within the subset that's there instead of the entire table contents. In other words, the two search terms are "AND"ed together, not "OR"ed.
Does anyone have ideas of how to implement this? I've done some research on regular expressions to pass to fnFilter, but have not found one that works yet.
Thanks
First let me say that Datatables is awesome, and an amazing functional enhancement for our product.
We have the normal filtering using the input box, and we have implemented filtering using a drop-down list. Both work fine - on their own. But, we want them to work together, so that if someone has filtered using the input box, and then we call fnFilter when the dropdown changes, we filter within the subset that's there instead of the entire table contents. In other words, the two search terms are "AND"ed together, not "OR"ed.
Does anyone have ideas of how to implement this? I've done some research on regular expressions to pass to fnFilter, but have not found one that works yet.
Thanks
This discussion has been closed.
Replies