diff options
Diffstat (limited to 'Zotlabs/Module')
-rw-r--r-- | Zotlabs/Module/Channel.php | 2 | ||||
-rw-r--r-- | Zotlabs/Module/Network.php | 4 | ||||
-rw-r--r-- | Zotlabs/Module/Search.php | 5 |
3 files changed, 5 insertions, 6 deletions
diff --git a/Zotlabs/Module/Channel.php b/Zotlabs/Module/Channel.php index a513523a7..5cf24615d 100644 --- a/Zotlabs/Module/Channel.php +++ b/Zotlabs/Module/Channel.php @@ -28,7 +28,7 @@ class Channel extends Controller { function init() { if (in_array(substr($_GET['search'], 0, 1), ['@', '!', '?']) || strpos($_GET['search'], 'https://') === 0) - goaway('search' . '?f=&search=' . $_GET['search']); + goaway(z_root() . '/search?f=&search=' . $_GET['search']); $which = null; if (argc() > 1) diff --git a/Zotlabs/Module/Network.php b/Zotlabs/Module/Network.php index 84c2463d6..8a1b51a18 100644 --- a/Zotlabs/Module/Network.php +++ b/Zotlabs/Module/Network.php @@ -21,12 +21,12 @@ class Network extends \Zotlabs\Web\Controller { } if(in_array(substr($_GET['search'],0,1),[ '@', '!', '?']) || strpos($_GET['search'], 'https://') === 0) - goaway('search' . '?f=&search=' . $_GET['search']); + goaway(z_root() . '/search?f=&search=' . $_GET['search']); if(count($_GET) < 2) { $network_options = get_pconfig(local_channel(),'system','network_page_default'); if($network_options) - goaway('network' . '?f=&' . $network_options); + goaway(z_root() . '/network?f=&' . $network_options); } $channel = App::get_channel(); diff --git a/Zotlabs/Module/Search.php b/Zotlabs/Module/Search.php index eeeff9613..8a87d98f7 100644 --- a/Zotlabs/Module/Search.php +++ b/Zotlabs/Module/Search.php @@ -14,7 +14,6 @@ class Search extends Controller { App::$data['search'] = escape_tags($_REQUEST['search']); } - function get($update = 0, $load = false) { if ((get_config('system', 'block_public')) || (get_config('system', 'block_public_search'))) { @@ -194,7 +193,7 @@ class Search extends Controller { if (local_channel()) { $r = q("SELECT mid, MAX(id) as item_id from item - WHERE ((( item.allow_cid = '' AND item.allow_gid = '' AND item.deny_cid = '' AND item.deny_gid = '' AND item_private = 0 ) + WHERE ((( item.allow_cid = '' AND item.allow_gid = '' AND item.deny_cid = '' AND item.deny_gid = '' AND item_private = 0 ) OR ( item.uid = %d )) OR item.owner_xchan = '%s' ) $item_normal $sql_extra @@ -210,7 +209,7 @@ class Search extends Controller { and owner_xchan in ( " . stream_perms_xchans(($observer) ? (PERMS_NETWORK | PERMS_PUBLIC) : PERMS_PUBLIC) . " )) $pub_sql ) OR owner_xchan = '%s') $item_normal - $sql_extra + $sql_extra group by mid, created order by created desc $pager_sql", dbesc($sys['xchan_hash']) ); |