From 48881ff821beef1c2c643cebe5d4c42e87337666 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 8 Dec 2008 00:01:00 +0000 Subject: [PATCH] Doc --- htdocs/master.inc.php | 2 +- htdocs/translate.class.php | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/htdocs/master.inc.php b/htdocs/master.inc.php index b740707bbfd..4ec9e5274f6 100644 --- a/htdocs/master.inc.php +++ b/htdocs/master.inc.php @@ -154,7 +154,7 @@ if (! empty($dolibarr_main_document_root_alt)) } } -// Defini prefix +// Define prefix if (isset($_SERVER["LLX_DBNAME"])) $dolibarr_main_db_prefix=$_SERVER["LLX_DBNAME"]; define('MAIN_DB_PREFIX',$dolibarr_main_db_prefix); diff --git a/htdocs/translate.class.php b/htdocs/translate.class.php index 1c10e223310..e3c97afd714 100644 --- a/htdocs/translate.class.php +++ b/htdocs/translate.class.php @@ -33,7 +33,7 @@ */ class Translate { - var $dir; // Directories with translation files + var $dir; // Directories that contains /langs subdirectory var $defaultlang; // Langue courante en vigueur de l'utilisateur @@ -48,7 +48,7 @@ class Translate { /** * \brief Constructeur de la classe - * \param dir Force directory that contains translation files + * \param dir Force directory that contains /langs subdirectory * \param conf Objet qui contient la config Dolibarr */ function Translate($dir = "",$conf) @@ -102,7 +102,7 @@ class Translate { $this->origlang=$srclang; - if ($srclang == 'auto') + if (empty($srclang) || $srclang == 'auto') { $langpref=$_SERVER['HTTP_ACCEPT_LANGUAGE']; $langpref=eregi_replace(";[^,]*","",$langpref);