The branch, master has been updated via ed34bb905448199dc317734bd4c9547b9aaa3a3f (commit) via 5f88219d18cc76bae06757806be85fb662604bcf (commit) via 5684d400593e4b7f57038c91e18c8f89c4cf9de0 (commit) via 9da795245ef207897bbb4ddb6b0706535549b753 (commit) via 180018d4dc071a5b9a14de740be2242eab66e051 (commit) from 3910ce61212e44d944ccbd924fd50d69419af548 (commit)
- Log ----------------------------------------------------------------- commit ed34bb905448199dc317734bd4c9547b9aaa3a3f Author: Michal Čihař mcihar@novell.com Date: Mon Jul 26 16:41:49 2010 +0200
Adjust documentation to gettext.
commit 5f88219d18cc76bae06757806be85fb662604bcf Author: Michal Čihař mcihar@novell.com Date: Mon Jul 26 16:40:43 2010 +0200
Included only from single place, no need for require_once.
commit 5684d400593e4b7f57038c91e18c8f89c4cf9de0 Author: Michal Čihař mcihar@novell.com Date: Mon Jul 26 16:39:55 2010 +0200
Documentation.
commit 9da795245ef207897bbb4ddb6b0706535549b753 Author: Michal Čihař mcihar@novell.com Date: Mon Jul 26 16:39:04 2010 +0200
It makes no sense load translations here
Either the message is translated or not, but we can not do much about it.
commit 180018d4dc071a5b9a14de740be2242eab66e051 Author: Michal Čihař mcihar@novell.com Date: Mon Jul 26 16:38:31 2010 +0200
Drop suppor from PMA_fatalError for str* variables.
It is not used anywhere now.
-----------------------------------------------------------------------
Summary of changes: config.sample.inc.php | 2 +- libraries/common.inc.php | 2 +- libraries/config.default.php | 3 +-- libraries/core.lib.php | 27 ++------------------------- 4 files changed, 5 insertions(+), 29 deletions(-)
diff --git a/config.sample.inc.php b/config.sample.inc.php index 679555b..da403fd 100644 --- a/config.sample.inc.php +++ b/config.sample.inc.php @@ -94,7 +94,7 @@ $cfg['SaveDir'] = '';
/** * Default language to use, if not browser-defined or user-defined - * (you find all languages in the file libraries/select_lang.lib.php) + * (you find all languages in the locale folder) * uncomment the desired line: * default = 'en' */ diff --git a/libraries/common.inc.php b/libraries/common.inc.php index 80866ff..a728c5a 100644 --- a/libraries/common.inc.php +++ b/libraries/common.inc.php @@ -557,7 +557,7 @@ $GLOBALS['footnotes'] = array(); /** * lang detection is done here */ -require_once './libraries/select_lang.lib.php'; +require './libraries/select_lang.lib.php';
/** * check for errors occurred while loading configuration diff --git a/libraries/config.default.php b/libraries/config.default.php index 28aa85e..4f71e56 100644 --- a/libraries/config.default.php +++ b/libraries/config.default.php @@ -1932,8 +1932,7 @@ $cfg['DefaultLang'] = 'en'; $cfg['DefaultConnectionCollation'] = 'utf8_general_ci';
/** - * Force: always use this language - must be defined in - * libraries/select_lang.lib.php + * Force: always use this language * $cfg['Lang'] = 'en'; * * Regular expression to limit listed languages, e.g. '^(cs|en)' for Czech and diff --git a/libraries/core.lib.php b/libraries/core.lib.php index dcbf177..c1a0b4b 100644 --- a/libraries/core.lib.php +++ b/libraries/core.lib.php @@ -220,30 +220,7 @@ function PMA_securePath($path) */ function PMA_fatalError($error_message, $message_args = null) { - // it could happen PMA_fatalError() is called before language file is loaded - if (! isset($GLOBALS['available_languages'])) { - $GLOBALS['cfg'] = array( - 'DefaultLang' => 'en', - ); - - // Loads the language file - require_once './libraries/select_lang.lib.php'; - - // $text_dir is set in po file - if (isset($text_dir)) { - $GLOBALS['text_dir'] = $text_dir; - } - } - - // $error_message could be a language string identifier: strString - if (substr($error_message, 0, 3) === 'str') { - if (isset($$error_message)) { - $error_message = $$error_message; - } elseif (isset($GLOBALS[$error_message])) { - $error_message = $GLOBALS[$error_message]; - } - } - + /* Use format string if applicable */ if (is_string($message_args)) { $error_message = sprintf($error_message, $message_args); } elseif (is_array($message_args)) { @@ -316,7 +293,7 @@ function PMA_getTableCount($db) $num_tables--; } } - + PMA_DBI_free_result($tables); } else { $num_tables = 0;
hooks/post-receive