protect_sprintf calls
implement protectSprintf function
This commit is contained in:
@@ -766,7 +766,7 @@ class Contact extends BaseModule
|
||||
if ($search) {
|
||||
$searching = true;
|
||||
$search_hdr = $search;
|
||||
$search_txt = DBA::escape(protect_sprintf(preg_quote($search)));
|
||||
$search_txt = DBA::escape(Strings::protectSprintf(preg_quote($search)));
|
||||
$sql_extra .= " AND (name REGEXP '$search_txt' OR url REGEXP '$search_txt' OR nick REGEXP '$search_txt') ";
|
||||
}
|
||||
|
||||
|
||||
@@ -241,7 +241,7 @@ class DFRN
|
||||
if (isset($category)) {
|
||||
$sql_post_table = sprintf(
|
||||
"INNER JOIN (SELECT `oid` FROM `term` WHERE `term` = '%s' AND `otype` = %d AND `type` = %d AND `uid` = %d ORDER BY `tid` DESC) AS `term` ON `item`.`id` = `term`.`oid` ",
|
||||
DBA::escape(protect_sprintf($category)),
|
||||
DBA::escape(Strings::protectSprintf($category)),
|
||||
intval(TERM_OBJ_POST),
|
||||
intval(TERM_CATEGORY),
|
||||
intval($owner_id)
|
||||
|
||||
Reference in New Issue
Block a user