In jquery datatable, I have to filter the result with exact match and highlight it. for exact match I am trying following code but it does not work. fiddle
t
Try
$('#search-inp').keyup(function(){ var key = $(this).val(); var regExp = "." if (key) regExp = "^\\s*" + key + "\\s*$"; table.columns(1).search(regExp, true).draw(); });
When search key is empty always set it to . matches any in regex.
key
.
any
regex