Reworked subfolder message count and all. Open to suggestions for the
[squirrelmail.git] / src / load_prefs.php
index fb2dd9e51dc4a29645a9061eca4b683cfc869006..0e8f7a9d197b58aebedb5bf67c95449374ebc8de 100644 (file)
@@ -37,8 +37,8 @@ $chosen_theme = (!$found_theme ? '' : $chosen_theme);
 if (isset($chosen_theme) && $found_theme && (file_exists($chosen_theme))) {
     @include_once($chosen_theme);
 } else {
-    if (isset($theme) && isset($theme[0]) && file_exists($theme[0]['PATH'])) {
-        @include_once($theme[0]['PATH']);
+    if (isset($theme) && isset($theme[$theme_default]) && file_exists($theme[$theme_default]['PATH'])) {
+        @include_once($theme[$theme_default]['PATH']);
     } else {
         /**
          * This theme as a failsafe if no themes were found. It makes
@@ -185,9 +185,11 @@ $location_of_buttons =
 $collapse_folders =
     getPref($data_dir, $username, 'collapse_folders', SMPREF_ON);
 
-/* show_html_default is a int value. */
 $show_html_default =
-    intval(getPref($data_dir, $username, 'show_html_default', SMPREF_OFF));
+   getPref($data_dir, $username, 'show_html_default', SMPREF_OFF);
+
+$enable_forward_as_attachment =
+   getPref($data_dir, $username, 'enable_forward_as_attachment', SMPREF_ON);
 
 $show_xmailer_default =
     getPref($data_dir, $username, 'show_xmailer_default', SMPREF_OFF );