Remove \' from search terms
This commit is contained in:
parent
b95dcb5a00
commit
1cd178646b
|
@ -262,10 +262,11 @@ echo $thispage;
|
|||
|
||||
function get_body_search($group, $terms) {
|
||||
GLOBAL $CONFIG, $config_name, $spooldir, $snippet_size;
|
||||
$terms = preg_replace("/'/", ' ', $terms);
|
||||
$terms = trim($terms);
|
||||
if($terms[0] !== '"' && substr($terms, -1) !== '"') {
|
||||
if($terms[0] !== '"' || substr($terms, -1) !== '"') {
|
||||
$terms = preg_replace('/"/', '', $terms);
|
||||
$terms = preg_replace('/\ /', '" "', $terms);
|
||||
$terms = preg_replace("/\ /", '" "', $terms);
|
||||
$terms = preg_replace('/"NEAR"/', 'NEAR', $terms);
|
||||
$terms = preg_replace('/"AND"/', 'AND', $terms);
|
||||
$terms = preg_replace('/"OR"/', 'OR', $terms);
|
||||
|
|
Loading…
Reference in New Issue