diff options
author | tony baldwin <tonybaldwin@gmx.com> | 2012-03-21 01:36:23 -0400 |
---|---|---|
committer | tony baldwin <tonybaldwin@gmx.com> | 2012-03-21 01:36:23 -0400 |
commit | e5c29fcc786cee73c08247824cb87e9ed65a2c36 (patch) | |
tree | 1e5a6fcf5ba20e5effdd60e6d6ffa5fadb11d9d7 /mod/search.php | |
parent | cf17606d0f6200296b1e6d67f9ae3fb797e0df69 (diff) | |
parent | b4a2dae0850ed72b61b008e44efa98f300ccd640 (diff) | |
download | volse-hubzilla-e5c29fcc786cee73c08247824cb87e9ed65a2c36.tar.gz volse-hubzilla-e5c29fcc786cee73c08247824cb87e9ed65a2c36.tar.bz2 volse-hubzilla-e5c29fcc786cee73c08247824cb87e9ed65a2c36.zip |
Merge remote branch 'upstream/master'
Diffstat (limited to 'mod/search.php')
-rwxr-xr-x | mod/search.php | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/mod/search.php b/mod/search.php index 386592ea1..50e7a6abc 100755 --- a/mod/search.php +++ b/mod/search.php @@ -93,8 +93,9 @@ function search_content(&$a) { return $o; // Here is the way permissions work in the search module... - // Only public wall posts can be shown + // Only public posts can be shown // OR your own posts if you are a logged in member + // No items will be shown if the member has a blocked profile wall. $s_regx = sprintf("AND ( `item`.`body` REGEXP '%s' OR `item`.`tag` REGEXP '%s' )", dbesc(preg_quote($search)), dbesc('\\]' . preg_quote($search) . '\\[')); @@ -104,7 +105,7 @@ function search_content(&$a) { $r = q("SELECT COUNT(*) AS `total` FROM `item` LEFT JOIN `contact` ON `contact`.`id` = `item`.`contact-id` LEFT JOIN `user` ON `user`.`uid` = `item`.`uid` WHERE `item`.`visible` = 1 AND `item`.`deleted` = 0 and `item`.`moderated` = 0 - AND (( `wall` = 1 AND `item`.`allow_cid` = '' AND `item`.`allow_gid` = '' AND `item`.`deny_cid` = '' AND `item`.`deny_gid` = '' AND `user`.`hidewall` = 0) + AND (( `item`.`allow_cid` = '' AND `item`.`allow_gid` = '' AND `item`.`deny_cid` = '' AND `item`.`deny_gid` = '' AND `item`.`private` = 0 AND `user`.`hidewall` = 0) OR `item`.`uid` = %d ) AND `contact`.`blocked` = 0 AND `contact`.`pending` = 0 $search_alg ", @@ -127,7 +128,7 @@ function search_content(&$a) { FROM `item` LEFT JOIN `contact` ON `contact`.`id` = `item`.`contact-id` LEFT JOIN `user` ON `user`.`uid` = `item`.`uid` WHERE `item`.`visible` = 1 AND `item`.`deleted` = 0 and `item`.`moderated` = 0 - AND (( `wall` = 1 AND `item`.`allow_cid` = '' AND `item`.`allow_gid` = '' AND `item`.`deny_cid` = '' AND `item`.`deny_gid` = '' AND `item`.`private` = 0 AND `user`.`hidewall` = 0 ) + AND (( `item`.`allow_cid` = '' AND `item`.`allow_gid` = '' AND `item`.`deny_cid` = '' AND `item`.`deny_gid` = '' AND `item`.`private` = 0 AND `user`.`hidewall` = 0 ) OR `item`.`uid` = %d ) AND `contact`.`blocked` = 0 AND `contact`.`pending` = 0 $search_alg |