diff --git a/upload/includes/sphinxapi.php b/upload/includes/api.sphinx.php similarity index 100% rename from upload/includes/sphinxapi.php rename to upload/includes/api.sphinx.php diff --git a/upload/includes/functions.php b/upload/includes/functions.php index df466b3ff..1faf95ed5 100644 --- a/upload/includes/functions.php +++ b/upload/includes/functions.php @@ -2510,14 +2510,11 @@ function init_sphinx () if (!isset($sphinx)) { - require(INC_DIR .'sphinxapi.php'); + require(INC_DIR .'api.sphinx.php'); $sphinx = new SphinxClient(); $sphinx->SetConnectTimeout(5); -# $sphinx->SetMaxQueryTime(2); $sphinx->SetRankingMode(SPH_RANK_NONE); -# $sphinx->SetMatchMode(SPH_MATCH_BOOLEAN); -# $sphinx->SetSortMode($mode, $sortby=""); } } @@ -2553,10 +2550,6 @@ function get_title_match_topics ($title_match_sql, $forum_ids = array()) { $sphinx->SetFilter('forum_id', $forum_ids, false); } - if (preg_match('#^"[^"]+"$#u', $title_match_sql)) - { - $sphinx->SetMatchMode(SPH_MATCH_PHRASE); - } if ($result = $sphinx->Query($title_match_sql, $where, $userdata['username'] .' ('. CLIENT_IP .')')) { if (!empty($result['matches']))