mirror of
https://git.friendi.ca/friendica/friendica.git
synced 2025-06-17 01:25:21 +02:00
preg_quote search strings
This commit is contained in:
parent
7eba8adbf7
commit
341fcce75e
2 changed files with 4 additions and 11 deletions
|
@ -364,8 +364,8 @@ function network_content(&$a, $update = 0) {
|
|||
if(x($_GET,'search')) {
|
||||
$search = escape_tags($_GET['search']);
|
||||
$sql_extra .= sprintf(" AND ( `item`.`body` REGEXP '%s' OR `item`.`tag` REGEXP '%s' ) ",
|
||||
dbesc($search),
|
||||
dbesc('\\]' . $search . '\\[')
|
||||
dbesc(preg_quote($search)),
|
||||
dbesc('\\]' . preg_quote($search) . '\\[')
|
||||
);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue