diff options
| author | Andreas Fischer <bantu@phpbb.com> | 2014-08-17 01:14:47 +0200 | 
|---|---|---|
| committer | Andreas Fischer <bantu@phpbb.com> | 2014-08-17 01:14:47 +0200 | 
| commit | f1e9c24c6649406d3b61a40d38cf329ffa59650a (patch) | |
| tree | f2ab862af904b5f48c2ff238c324543504cef564 | |
| parent | f3076cf4443b2cc5d663cece086298b64e16074e (diff) | |
| parent | 4ff5aa18aeb26d9d48d93bcde69082bc969896ef (diff) | |
| download | forums-f1e9c24c6649406d3b61a40d38cf329ffa59650a.tar forums-f1e9c24c6649406d3b61a40d38cf329ffa59650a.tar.gz forums-f1e9c24c6649406d3b61a40d38cf329ffa59650a.tar.bz2 forums-f1e9c24c6649406d3b61a40d38cf329ffa59650a.tar.xz forums-f1e9c24c6649406d3b61a40d38cf329ffa59650a.zip | |
Merge branch 'develop-ascraeus' into develop
* develop-ascraeus:
  [ticket/12986] Fix detection of common words in search
| -rw-r--r-- | phpBB/search.php | 5 | 
1 files changed, 2 insertions, 3 deletions
| diff --git a/phpBB/search.php b/phpBB/search.php index 071db30f3d..67f6f4dbb5 100644 --- a/phpBB/search.php +++ b/phpBB/search.php @@ -281,12 +281,11 @@ if ($keywords || $author || $author_id || $search_id || $submit)  		trigger_error($error);  	} -	$common_words = $search->get_common_words(); -  	// let the search module split up the keywords  	if ($keywords)  	{  		$correct_query = $search->split_keywords($keywords, $search_terms); +		$common_words = $search->get_common_words();  		if (!$correct_query || (!$search->get_search_query() && !sizeof($author_id_ary) && !$search_id))  		{  			$ignored = (sizeof($common_words)) ? sprintf($user->lang['IGNORED_TERMS_EXPLAIN'], implode(' ', $common_words)) . '<br />' : ''; @@ -599,7 +598,7 @@ if ($keywords || $author || $author_id || $search_id || $submit)  		'SEARCH_MATCHES'	=> $l_search_matches,  		'SEARCH_WORDS'		=> $keywords,  		'SEARCHED_QUERY'	=> $search->get_search_query(), -		'IGNORED_WORDS'		=> (sizeof($common_words)) ? implode(' ', $common_words) : '', +		'IGNORED_WORDS'		=> (!empty($common_words)) ? implode(' ', $common_words) : '',  		'PHRASE_SEARCH_DISABLED'		=> $phrase_search_disabled, | 
