Search
13880 results 3101-3110
Forum
- 18th Jun 2014Datatable filter search on two columns ?DataTables' column filtering is an AND operation - there is no option for OR filtering in the built in filtering. For that you would need a custom filtering plug-in: http://datatables.net/examples/plug-ins/range_filtering.html Alternatively, if you are only using 4 columns and two aren't filterable, you could just use the global filter? Allan
- 6th Jun 2014Disable search on all but on columnThis seems to have done the trick - is this acceptable "aoColumns": [ { "bSearchable": false }, null, { "bSearchable": false } ],
- 22nd May 2014Button event not firing after search filter and/or pagination (e.g. not on first page)See the FAQ.
- 4th Apr 2014Search doesn't work after xeditable update@Allan. Thank you for the clue. Instead of changing the values using jQuery tags. I used fnUpdate to update the values.
- 17th Mar 2014[1.10] How do I search a column with regular expression? - column().search() with Regular ExpressionThanks very much. Its takes a while, but I get there :-) Yes, fnGetData and friends will work in 1.10. The 'New API' section of the upgrade notes mentions this: http://next.datatables.net/new/1.10 Allan
- 10th Mar 2014Custom Filter to search at the beginning of each WordProblem solved, for anyone wondering, the solution was far simpler than i expected. I'm not saying this is the optimal solution, but atleast its a working one. In the server_processing.php file, there is lines for Filtering : [code] /* * Filtering * NOTE this does not match the built-in DataTables filtering which does it * word by word on any field. It's possible to do here, but concerned about efficiency * on very large tables, and MySQL's regex functionality is very limited */ $sWhere = ""; if ( isset($_GET['sSearch']) && $_GET['sSearch'] != "" ) { $sWhere = "WHERE ("; for ( $i=0 ; $i<count($aColumns) ; $i++ ) { $sWhere .= "".$aColumns[$i]." LIKE '".mysql_real_escape_string( $_GET['sSearch'] )."%' OR "; } $sWhere = substr_replace( $sWhere, "", -3 ); $sWhere .= ')'; } [/code] we are interested in the $sWhere variable, which contained previously [code] "".$aColumns[$i]." LIKE '%" [/code] Once the first % removed, it looks for the first characters an exact match as what you type in. (the second % ensure it still display all the "possible" results, not only exact matches.) Hope it helps other people, Flavio
- 4th Feb 2014Extend Search FunctionBasically you can't - its a private function. What I would suggest is you create a custom feature plug-in which just calls fnFilter (which is basically all _fnFilterCreateSearch does after it has made the input box). See: http://datatables.net/blog/Creating_feature_plug-ins Allan
- 7th Jan 2014Is there a way to "remember" the search values of column range filters? (similar to aoPreSearchCols)Thanks Allan! Looks good, and it looks like what I was looking for.
- 12th Dec 2013How can I put the search label inside the input?Oh wow :) That was simple. Thank you so much!
- 9th Dec 2013GROUP BY breaks Search functionI was able to figure it out using $sGroup = "GROUP BY accounts.accountname"; Added $sGroup after $sWhere Thank you