Browse Source

when falling back to the default theme, set $chosen_theme to the path
of default to make functions that depend on $chosen_theme work
correctly (most notably the select list under display preferences which
would have Alien Glow selected when user has no theme set). Thanks Tim Craig
for the bugreport.

Thijs Kinkhorst 22 years ago
parent
commit
92f83a0229
2 changed files with 3 additions and 0 deletions
  1. 2 0
      ChangeLog
  2. 1 0
      include/load_prefs.php

+ 2 - 0
ChangeLog

@@ -60,6 +60,8 @@ Version 1.5.0 -- CVS
   - Fix when forwarding messages as attachment from message list, the displayed subject
   - Fix when forwarding messages as attachment from message list, the displayed subject
     was wrong (appearing to the user that the wrong messages were attached).
     was wrong (appearing to the user that the wrong messages were attached).
     Closes #772371.
     Closes #772371.
+  - Fix that when user has no theme preference set, Alien Glow would be selected under
+    display preferences in stead of Default.
 
 
 **************************************
 **************************************
 *** SquirrelMail Stable Series 1.4 ***
 *** SquirrelMail Stable Series 1.4 ***

+ 1 - 0
include/load_prefs.php

@@ -46,6 +46,7 @@ if (isset($chosen_theme) && $found_theme && (file_exists($chosen_theme))) {
 } else {
 } else {
     if (isset($theme) && isset($theme[$theme_default]) && file_exists($theme[$theme_default]['PATH'])) {
     if (isset($theme) && isset($theme[$theme_default]) && file_exists($theme[$theme_default]['PATH'])) {
         @include_once($theme[$theme_default]['PATH']);
         @include_once($theme[$theme_default]['PATH']);
+        $chosen_theme = $theme[$theme_default]['PATH'];
     } else {
     } else {
         /**
         /**
          * This theme as a failsafe if no themes were found. It makes
          * This theme as a failsafe if no themes were found. It makes