From 2b2bbf787c55e8922ae1c06242be1120a7e91eb7 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Fri, 15 Mar 2013 08:23:39 +0100 Subject: [ticket/11438] Add helpful comments from sample config to ACP output PHPBB3-11438 --- phpBB/includes/search/fulltext_sphinx.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'phpBB/includes') diff --git a/phpBB/includes/search/fulltext_sphinx.php b/phpBB/includes/search/fulltext_sphinx.php index 48445d0794..48e6b5aaec 100644 --- a/phpBB/includes/search/fulltext_sphinx.php +++ b/phpBB/includes/search/fulltext_sphinx.php @@ -258,13 +258,13 @@ class phpbb_search_fulltext_sphinx $config_object = new phpbb_search_sphinx_config($this->config_file_data); $config_data = array( 'source source_phpbb_' . $this->id . '_main' => array( - array('type', $this->dbtype), + array('type', $this->dbtype . ' #mysql or pgsql'), // This config value sql_host needs to be changed incase sphinx and sql are on different servers - array('sql_host', $dbhost), + array('sql_host', $dbhost . ' #SQL server host sphinx connects to'), array('sql_user', $dbuser), array('sql_pass', $dbpasswd), array('sql_db', $dbname), - array('sql_port', $dbport), + array('sql_port', $dbport . ' #optional, default is 3306 for mysql and 5432 for pgsql'), array('sql_query_pre', 'SET NAMES \'utf8\''), array('sql_query_pre', 'UPDATE ' . SPHINX_TABLE . ' SET max_doc_id = (SELECT MAX(post_id) FROM ' . POSTS_TABLE . ') WHERE counter_id = 1'), array('sql_query_range', 'SELECT MIN(post_id), MAX(post_id) FROM ' . POSTS_TABLE . ''), -- cgit v1.2.1 From c50af280770a9db13043a41e34238a2434176936 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Sat, 16 Mar 2013 01:18:15 +0100 Subject: [ticket/11438] Add spaces after # comment start and before \ line breaks PHPBB3-11438 --- phpBB/includes/search/fulltext_sphinx.php | 6 +++--- phpBB/includes/search/sphinx/config_variable.php | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'phpBB/includes') diff --git a/phpBB/includes/search/fulltext_sphinx.php b/phpBB/includes/search/fulltext_sphinx.php index 48e6b5aaec..28761792ec 100644 --- a/phpBB/includes/search/fulltext_sphinx.php +++ b/phpBB/includes/search/fulltext_sphinx.php @@ -258,13 +258,13 @@ class phpbb_search_fulltext_sphinx $config_object = new phpbb_search_sphinx_config($this->config_file_data); $config_data = array( 'source source_phpbb_' . $this->id . '_main' => array( - array('type', $this->dbtype . ' #mysql or pgsql'), + array('type', $this->dbtype . ' # mysql or pgsql'), // This config value sql_host needs to be changed incase sphinx and sql are on different servers - array('sql_host', $dbhost . ' #SQL server host sphinx connects to'), + array('sql_host', $dbhost . ' # SQL server host sphinx connects to'), array('sql_user', $dbuser), array('sql_pass', $dbpasswd), array('sql_db', $dbname), - array('sql_port', $dbport . ' #optional, default is 3306 for mysql and 5432 for pgsql'), + array('sql_port', $dbport . ' # optional, default is 3306 for mysql and 5432 for pgsql'), array('sql_query_pre', 'SET NAMES \'utf8\''), array('sql_query_pre', 'UPDATE ' . SPHINX_TABLE . ' SET max_doc_id = (SELECT MAX(post_id) FROM ' . POSTS_TABLE . ') WHERE counter_id = 1'), array('sql_query_range', 'SELECT MIN(post_id), MAX(post_id) FROM ' . POSTS_TABLE . ''), diff --git a/phpBB/includes/search/sphinx/config_variable.php b/phpBB/includes/search/sphinx/config_variable.php index 35abe281cb..2c1d35a49c 100644 --- a/phpBB/includes/search/sphinx/config_variable.php +++ b/phpBB/includes/search/sphinx/config_variable.php @@ -75,6 +75,6 @@ class phpbb_search_sphinx_config_variable */ function to_string() { - return "\t" . $this->name . ' = ' . str_replace("\n", "\\\n", $this->value) . ' ' . $this->comment . "\n"; + return "\t" . $this->name . ' = ' . str_replace("\n", " \\\n", $this->value) . ' ' . $this->comment . "\n"; } } -- cgit v1.2.1