updated changelog
[squirrelmail.git] / src / load_prefs.php
index 31389dfc4f6f59187ac97506b99f83c545fd8e60..3691d079c062912dce0f26515a343e492bcb2587 100644 (file)
                 break;
          }
    }
-   if (!$in_ary) {
-               $chosen_theme = "";
-   }
 
-   if ((isset($chosen_theme)) && (file_exists($chosen_theme))) {
-      require("$chosen_theme");
+   if ($in_ary && (file_exists($chosen_theme))) {
+      $loaded=@include($chosen_theme);
    } else {
       if (file_exists($theme[0]["PATH"])) {
          require($theme[0]["PATH"]);
@@ -61,7 +58,9 @@
           $color[11]  = "#770000"; // (dark red)       Special Folders color
       }
    }
-
+    if (!isset($loaded)) 
+      echo _("Unable to load chosen theme file:") . ' "' .
+       $chosen_theme . '"';
     if (!isset($download_php)) session_register("theme_css");
 
    $use_javascript_addr_book = getPref($data_dir, $username, "use_javascript_addr_book");
    if ($use_signature == "")
       $use_signature = false;
 
+   $prefix_sig = getPref($data_dir, $username, "prefix_sig");
+   if ($prefix_sig == "")
+      $prefix_sig = false;
+
    $left_refresh = getPref($data_dir, $username, "left_refresh");
    if ($left_refresh == "")
       $left_refresh = false;
    $location_of_buttons = getPref($data_dir, $username, 'location_of_buttons');
    if ($location_of_buttons == '')
        $location_of_buttons = 'between';
+       
+   $collapse_folders = getPref($data_dir, $username, 'collapse_folders');
+   
+   $show_html_default = getPref($data_dir, $username, 'show_html_default');
 
    do_hook("loading_prefs");