From: kink Date: Sun, 9 Jan 2005 22:28:30 +0000 (+0000) Subject: Have configtest check whether the sq_default_language is actually installed. X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=07337c9ba899ec77efabf5316c5dcb6279a8fcc6;p=squirrelmail.git Have configtest check whether the sq_default_language is actually installed. Might hint people that didn't download the locales package. git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@8616 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- diff --git a/src/configtest.php b/src/configtest.php index 99201f6d..b02a316b 100644 --- a/src/configtest.php +++ b/src/configtest.php @@ -172,6 +172,24 @@ foreach($theme as $thm) { echo $IND . "Themes OK.
\n"; +if ( $squirrelmail_default_language != 'en_US' ) { + $loc_path = SM_PATH .'locale/'.$squirrelmail_default_language.'/LC_MESSAGES/squirrelmail.mo'; + if( ! file_exists( $loc_path ) ) { + do_err('You have set ' . $squirrelmail_default_language . + ' as your default language, but I cannot find this translation (should be '. + 'in ' . $loc_path . '). Please note that you have to download translations '. + 'separately from the main SquirrelMail package.', FALSE); + } elseif ( ! is_readable( $loc_path ) ) { + do_err('You have set ' . $squirrelmail_default_language . + ' as your default language, but I cannot read this translation (file '. + 'in ' . $loc_path . ' unreadable).', FALSE); + } else { + echo $IND . "Default language OK.
\n"; + } +} else { + echo $IND . "Default language OK.
\n"; +} + echo $IND . "Base URL detected as: " . htmlspecialchars(get_location()) . "
\n"; @@ -440,4 +458,4 @@ if( empty($ldap_server) ) { \ No newline at end of file +?>