use Friendica\Util\Strings;
function search_saved_searches() {
-
$o = '';
$search = (!empty($_GET['search']) ? Strings::escapeTags(trim(rawurldecode($_GET['search']))) : '');
}
return $o;
-
}
function search_init(App $a) {
-
$search = (!empty($_GET['search']) ? Strings::escapeTags(trim(rawurldecode($_GET['search']))) : '');
if (local_user()) {
unset($_SESSION['theme']);
unset($_SESSION['mobile-theme']);
}
-
-
-
}
function search_content(App $a) {
-
if (Config::get('system','block_public') && !local_user() && !remote_user()) {
notice(L10n::t('Public access denied.') . EOL);
return;
return BaseSearchModule::performSearch();
}
+ if (parse_url($search, PHP_URL_SCHEME) != '') {
+ $id = Item::fetchByLink($search);
+ if (!empty($id)) {
+ $item = Item::selectFirst(['guid'], ['id' => $id]);
+ if (DBA::isResult($item)) {
+ $a->internalRedirect('display/' . $item['guid']);
+ }
+ }
+ }
+
if (!empty($_GET['search-option']))
switch($_GET['search-option']) {
case 'fulltext':