From 2d2acf5e4e15a4089ed02314616fa704b8b9bd11 Mon Sep 17 00:00:00 2001 From: pdontthink Date: Tue, 17 Jul 2007 22:20:15 +0000 Subject: [PATCH] Fix login error for users with no theme git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@12549 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- functions/page_header.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/functions/page_header.php b/functions/page_header.php index f69be5bb..00b64032 100644 --- a/functions/page_header.php +++ b/functions/page_header.php @@ -72,10 +72,12 @@ function displayHtmlHeader( $title = 'SquirrelMail', $xtra = '', $do_hook = TRUE // 2. Option user-defined stylesheet from preferences. if (!empty($used_theme) && $used_theme != 'none') { /** - * All styles just point to a directory, so we need to include all .css - * files in that directory. + * All styles (except "none" - ugh) just point to a directory, + * so we need to include all .css files in that directory. */ - $styles = list_files($used_theme, '.css'); +//FIXME: rid ourselves of "none" strings! I didn't do it here because I think the problem is that the theme itself should never be "none" (? well, what else would it be? if "none" theme is actually OK, then is there a constant to use below in stead of a hard-coded string?) + $styles = $used_theme == 'none' ? array() + : list_files($used_theme, '.css'); foreach ($styles as $sheet) { $aUserStyles[] = $used_theme .'/'.$sheet; } -- 2.25.1