fixed warning and improved url () filtering
[squirrelmail.git] / functions / display_messages.php
index 023913b03a59a1365da508fefd30bfd99f9a6576..470a5d359ab0733a8ef1d0c7707a247b538e4508 100644 (file)
@@ -3,12 +3,11 @@
 /**
  * display_messages.php
  *
- * Copyright (c) 1999-2005 The SquirrelMail Project Team
- * Licensed under the GNU GPL. For full terms see the file COPYING.
- *
  * This contains all messages, including information, error, and just
  * about any other message you can think of.
  *
+ * @copyright © 1999-2005 The SquirrelMail Project Team
+ * @license http://opensource.org/licenses/gpl-license.php GNU Public License
  * @version $Id$
  * @package squirrelmail
  */
@@ -84,7 +83,8 @@ function plain_error_message($message, $color) {
  */
 function logout_error( $errString, $errTitle = '' ) {
     global $frame_top, $org_logo, $org_name, $org_logo_width, $org_logo_height,
-           $hide_sm_attributions, $version, $squirrelmail_language, $color;
+           $hide_sm_attributions, $version, $squirrelmail_language, 
+           $color, $theme, $theme_default;
 
     $base_uri = sqm_baseuri();
 
@@ -106,7 +106,10 @@ function logout_error( $errString, $errTitle = '' ) {
         $frame_top = '_top';
     }
 
-    // TODO: load default theme if possible
+    // load default theme if possible
+    if (!isset($color) && @file_exists($theme[$theme_default]['PATH']))
+        @include ($theme[$theme_default]['PATH']);
+
     if ( !isset( $color ) ) {
         $color = array();
         $color[0]  = '#dcdcdc';  /* light gray    TitleBar               */