diff --git a/e107_admin/language.php b/e107_admin/language.php index dd98ad210..e5854ea61 100644 --- a/e107_admin/language.php +++ b/e107_admin/language.php @@ -45,6 +45,7 @@ if (isset($_POST['submit_prefs']) && isset($_POST['mainsitelanguage'])) $temp['multilanguage_subdomain'] = $_POST['multilanguage_subdomain']; $temp['multilanguage_domain'] = $_POST['multilanguage_domain']; $temp['sitelanguage'] = $_POST['mainsitelanguage']; + $temp['adminlanguage'] = $_POST['mainadminlanguage']; $temp['noLanguageSubs'] = $_POST['noLanguageSubs']; if ($admin_log->logArrayDiffs($temp, $pref, 'LANG_01')) { @@ -481,7 +482,29 @@ function multilang_prefs() $text .= $frm->select('mainsitelanguage',$lanlist,$sellan,"useValues=1"); $text .= " - + "; + + + if(isset($_SERVER['E_DEV_LANGUAGE']) && $_SERVER['E_DEV_LANGUAGE'] === 'true') + { + + $text .= " + + ".LANG_LAN_50.": + "; + + $sellan = preg_replace("/lan_*.php/i", "", $pref['adminlanguage']); + + $text .= $frm->select('mainadminlanguage',$lanlist,$sellan,array("useValues"=>1,"default" => LANG_LAN_14)); + $text .= " + + "; + + } + + + + $text .= " ".LANG_LAN_12.": diff --git a/e107_core/xml/default_install.xml b/e107_core/xml/default_install.xml index 366bcf18e..d5e551660 100644 --- a/e107_core/xml/default_install.xml +++ b/e107_core/xml/default_install.xml @@ -6,6 +6,7 @@ 0 0 admin_dark.css + 0 infopanel bootstrap diff --git a/e107_handlers/e107_class.php b/e107_handlers/e107_class.php index 77e557c99..d688c3133 100644 --- a/e107_handlers/e107_class.php +++ b/e107_handlers/e107_class.php @@ -2277,7 +2277,7 @@ class e107 { return FALSE; } - $path = str_replace(e_LANGUAGE, 'English', $path); + // $path = str_replace(e_LANGUAGE, 'English', $path); self::getMessage()->addDebug("Couldn't load language file: ".$path); } $ret = ($force) ? include($path) : include_once($path); diff --git a/e107_handlers/language_class.php b/e107_handlers/language_class.php index ef98bbd31..ab7059ad1 100644 --- a/e107_handlers/language_class.php +++ b/e107_handlers/language_class.php @@ -268,7 +268,7 @@ class language{ if(!$lang) { - return $pref['sitelanguage']; + return (ADMIN_AREA && vartrue($pref['adminlanguage'])) ? $pref['adminlanguage'] : $pref['sitelanguage']; } if(strpos($lang,"debug")!==FALSE) @@ -531,8 +531,8 @@ class language{ $session->set('e_language', $user_language); } else - { - $user_language = $pref['sitelanguage']; + { + $user_language = (e_ADMIN_AREA && vartrue($pref['adminlanguage'])) ? $pref['adminlanguage'] : $pref['sitelanguage']; if($session->is('e_language')) { diff --git a/e107_languages/English/admin/lan_language.php b/e107_languages/English/admin/lan_language.php index abe73d016..f67b3141e 100644 --- a/e107_languages/English/admin/lan_language.php +++ b/e107_languages/English/admin/lan_language.php @@ -50,4 +50,6 @@ define("LANG_LAN_34", "Available Language Packs"); define("LANG_LAN_35", "The following language packs are available for this version of e107."); define("LANG_LAN_36", "Language-Pack errors found! Please first verify your language files are without errors, before creating a language-pack."); +define("LANG_LAN_50", "Admin-Area Interface Language"); + ?> \ No newline at end of file