[SOLVED] Search (Filter) not working
[SOLVED] Search (Filter) not working
MrBaseball34
Posts: 96Questions: 0Answers: 0
I am using server-side processing and when I try to use the search, it returns the "JSON cannot be parsed" error.
Not sure why this is happening.
Can anyone help out? What code do I need to post?
Not sure why this is happening.
Can anyone help out? What code do I need to post?
This discussion has been closed.
Replies
However, it seems to be filtering wrong.
Since the DataTable that I'm using is "dynamic", meaning depending upon what param I pass to the page it wil have a different number of columns, and, even though the columns may differ, I have been able to use the aoColumns variable to define it but the WHERE is being built with all columns, not just the ones where bSearchable is set to true.
[code]
[bRegex] => false
[sSearch_0] =>
[bRegex_0] => false
[bSearchable_0] => true
[sSearch_1] =>
[bRegex_1] => false
[bSearchable_1] => true
[sSearch_2] =>
[bRegex_2] => false
[bSearchable_2] => true
[/code]
Even though it has aoColumns defined like this:
[code]
"aoColumns": [{ "bSearchable": true },
null,
{ "bSearchable": true }],
[/code]
How would I clear sSearch when the table is first built?
If I click on a link to another page that has the same table, the search value is persistent and it filters the values in the table when it loads.
[code]
"aoColumns": [{ "bSearchable": true },
{ "bSearchable": false },
{ "bSearchable": true }],
[/code]
For some reason, if there are many columns of different types, the search goes on "Processing..." without explaining why is failing