index b54fea5f0f7a709ea16b37a8cac32c84aebdba20..05990a151eade1cee0e027a6b7e78f1039af60d0 100644 (file)
}
/* Language setup */
-if ((!isset($config)) || $config->get_cfg_value("lang") == ""){
+if ((!isset($config)) || $config->get_cfg_value("language") == ""){
$lang= get_browser_language();
} else {
- $lang= $config->get_cfg_value("lang");
+ $lang= $config->get_cfg_value("language");
}
-$lang.=".UTF-8";
putenv("LANGUAGE=");
putenv("LANG=$lang");
setlocale(LC_ALL, $lang);
/* Create smarty & Set template compile directory */
$smarty= new smarty();
-$smarty->compile_dir= $config->get_cfg_value("compile", '/var/spool/gosa/');
+if (isset($config)){
+ $smarty->compile_dir= $config->get_cfg_value("compile", '/var/spool/gosa/');
+} else {
+ $smarty->compile_dir= '/var/spool/gosa/';
+}
/* If GET request is posted, the logout was forced by pressing the link */
if (isset($_GET['request'])){
session::destroy ();
/* If we're not using htaccess authentication, just redirect... */
- if ($config->get_cfg_value("htaccess_auth") == "true"){
+ if (isset($config) && $config->get_cfg_value("htaccessAuthentication") == "true"){
/* Else notice that the user has to close the browser... */
$smarty->display (get_template_path('headers.tpl'));