|
From: Paul S. O. <ps...@us...> - 2002-01-14 14:16:58
|
Update of /cvsroot/phpbb/phpBB2
In directory usw-pr-cvs1:/tmp/cvs-serv12232
Modified Files:
search.php
Log Message:
Finished implementation of title searching ... this will please at least one person :)
Index: search.php
===================================================================
RCS file: /cvsroot/phpbb/phpBB2/search.php,v
retrieving revision 1.55
retrieving revision 1.56
diff -C2 -r1.55 -r1.56
*** search.php 2002/01/12 17:00:32 1.55
--- search.php 2002/01/14 14:16:54 1.56
***************
*** 343,351 ****
$stopword_array = @file($phpbb_root_path . "language/lang_" . $board_config['default_lang'] . "/search_stopwords.txt");
- $cleaned_search = clean_words_search($query_keywords);
- $cleaned_search = remove_stop_words($cleaned_search, $stopword_array);
- $cleaned_search = replace_synonyms($cleaned_search, $synonym_array);
-
$split_search = array();
$split_search = split_words($cleaned_search);
--- 343,348 ----
$stopword_array = @file($phpbb_root_path . "language/lang_" . $board_config['default_lang'] . "/search_stopwords.txt");
$split_search = array();
+ $cleaned_search = clean_words("search", $query_keywords, $stopword_array, $synonym_array);
$split_search = split_words($cleaned_search);
***************
*** 353,359 ****
$word_count = 0;
$word_match = array();
$result_list = array();
- $current_match_type = "and";
for($i = 0; $i < count($split_search); $i++)
--- 350,357 ----
$word_count = 0;
+ $current_match_type = "and";
+
$word_match = array();
$result_list = array();
for($i = 0; $i < count($split_search); $i++)
***************
*** 423,427 ****
--- 421,429 ----
}
}
+
$word_count++;
+
+ $db->sql_freeresult($result);
+
}
}
***************
*** 513,516 ****
--- 515,520 ----
$search_sql .= "t.topic_id IN ($sql_post_id_in) ";
+
+ $db->sql_freeresult($result);
}
else
***************
*** 1332,1336 ****
"L_SEARCH_AUTHOR_EXPLAIN" => $lang['Search_author_explain'],
"L_SEARCH_ANY_TERMS" => $lang['Search_for_any'],
! "L_SEARCH_ALL_TERMS" => $lang['Search_for_all'],
"L_CATEGORY" => $lang['Category'],
"L_RETURN_FIRST" => $lang['Return_first'],
--- 1336,1342 ----
"L_SEARCH_AUTHOR_EXPLAIN" => $lang['Search_author_explain'],
"L_SEARCH_ANY_TERMS" => $lang['Search_for_any'],
! "L_SEARCH_ALL_TERMS" => $lang['Search_for_all'],
! "L_SEARCH_MESSAGE_ONLY" => $lang['Search_msg_only'],
! "L_SEARCH_MESSAGE_TITLE" => $lang['Search_title_msg'],
"L_CATEGORY" => $lang['Category'],
"L_RETURN_FIRST" => $lang['Return_first'],
|