mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-30 21:40:43 +02:00
- correctly transfer the search query across search result pages
- changed highlighting so foo* will match foo again [Bug #10031] - restructured magic urls (functionality still mostly the same), added a check for entities in urls and punctuation at the end of magic urls [Bugs #10639, #10293] - undid the workaround for urls in quotes, as it's fixed by the new magic url handling - allow magic urls enclosed in BBCode [Bug #10319] - added handling for IPv6 addresses to the IP checking without adding extra options [Bug #9538] - correctly handle search in search results of search queries with brackets [Bug #10581] - added information about requirements for auth_apache [Bug #10107] git-svn-id: file:///svn/phpbb/trunk@7559 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@@ -135,7 +135,7 @@ if ($keywords || $author || $author_id || $search_id || $submit)
|
||||
}
|
||||
|
||||
// Which forums should not be searched? Author searches are also carried out in unindexed forums
|
||||
if (empty($search->search_query) && sizeof($author_id_ary))
|
||||
if (empty($keywords) && sizeof($author_id_ary))
|
||||
{
|
||||
$ex_fid_ary = array_keys($auth->acl_getf('!f_read', true));
|
||||
}
|
||||
@@ -460,7 +460,7 @@ if ($keywords || $author || $author_id || $search_id || $submit)
|
||||
|
||||
$u_search = append_sid("{$phpbb_root_path}search.$phpEx", $u_sort_param . $u_show_results);
|
||||
$u_search .= ($search_id) ? '&search_id=' . $search_id : '';
|
||||
$u_search .= ($u_hilit) ? '&keywords=' . $u_hilit : '';
|
||||
$u_search .= ($u_hilit) ? '&keywords=' . urlencode(htmlspecialchars_decode($search->search_query)) : '';
|
||||
$u_search .= ($topic_id) ? '&t=' . $topic_id : '';
|
||||
$u_search .= ($author) ? '&author=' . urlencode(htmlspecialchars_decode($author)) : '';
|
||||
$u_search .= ($author_id) ? '&author_id=' . $author_id : '';
|
||||
@@ -711,7 +711,8 @@ if ($keywords || $author || $author_id || $search_id || $submit)
|
||||
$hilit_array = array_filter(explode('|', $hilit), 'strlen');
|
||||
foreach ($hilit_array as $key => $value)
|
||||
{
|
||||
$hilit_array[$key] = str_replace('\*', '\w+?', preg_quote($value, '#'));
|
||||
$hilit_array[$key] = str_replace('\*', '\w*?', preg_quote($value, '#'));
|
||||
$hilit_array[$key] = preg_replace('#(^|\s)\\\\w\*\?(\s|$)#', '$1\w+?$2', $hilit_array[$key]);
|
||||
}
|
||||
$hilit = implode('|', $hilit_array);
|
||||
}
|
||||
@@ -812,7 +813,7 @@ if ($keywords || $author || $author_id || $search_id || $submit)
|
||||
$template->assign_block_vars('searchresults', array(
|
||||
'S_IGNORE_POST' => true,
|
||||
|
||||
'L_IGNORE_POST' => sprintf($user->lang['POST_BY_FOE'], $row['username'], "<a href=\"$u_search&p=" . $row['post_id'] . '&view=show#p' . $row['post_id'] . '">', '</a>'))
|
||||
'L_IGNORE_POST' => sprintf($user->lang['POST_BY_FOE'], $row['username'], "<a href=\"$u_search&start=$start&p=" . $row['post_id'] . '&view=show#p' . $row['post_id'] . '">', '</a>'))
|
||||
);
|
||||
|
||||
continue;
|
||||
|
Reference in New Issue
Block a user