diff --git a/Connections/database_functions.php b/Connections/database_functions.php index 02823cb..2f658ca 100644 --- a/Connections/database_functions.php +++ b/Connections/database_functions.php @@ -330,9 +330,9 @@ function highlightKeywords($text, $keyword) { $wordsAry = explode(" ", $keyword); $wordsCount = count($wordsAry); - // Using REGEXP so remove regex from search - $find = array('/\*/', '/\./', '/\$/', '/\^/', '/\?/', '/\+/', '/\[/', '/\]/', '/\|/', '/\(/', '/\)/', '/\,/', '/\{/', '/\}/', '/\:/', '/\\\/'); - $replace = array('', '', '', '', '', '', '', '', '', '', '', '', '', '', '', ''); + // Using REGEXP, this removes regex from search + $find = array('/[\*\.\$\^\?\+\[\]\|\(\)\,\{\}\:\\\]/'); + $replace = array(''); for($i=0;$i<$wordsCount;$i++) {