From cf84f234fec0ac7b47ded4820df842bfb81fbea0 Mon Sep 17 00:00:00 2001 From: CaMer0n Date: Sat, 8 Sep 2007 01:35:42 +0000 Subject: [PATCH] bugfix: filesize() on missing user.js was causing php error. --- e107_themes/templates/header_default.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/e107_themes/templates/header_default.php b/e107_themes/templates/header_default.php index 8b20e908f..a5856ba0a 100644 --- a/e107_themes/templates/header_default.php +++ b/e107_themes/templates/header_default.php @@ -6,9 +6,9 @@ | Released under the terms and conditions of the GNU General Public License (http://gnu.org). | | $Source: /cvs_backup/e107_0.8/e107_themes/templates/header_default.php,v $ -| $Revision: 1.12 $ -| $Date: 2007-09-02 08:42:11 $ -| $Author: e107steved $ +| $Revision: 1.13 $ +| $Date: 2007-09-08 01:35:42 $ +| $Author: e107coders $ +-----------------------------------------------------------------------------------------------+ */ @@ -106,12 +106,14 @@ if (isset($theme_js_php) && $theme_js_php) { echo "\n"; } if (file_exists(THEME.'theme.js')) { echo "\n"; } - if (filesize(e_FILE.'user.js')) { echo "\n"; } + if (is_readable(e_FILE.'user.js') && filesize(e_FILE.'user.js')) { echo "\n"; } if (file_exists(THEME.'theme.vbs')) { echo "\n"; } if (filesize(e_FILE.'user.vbs')) { echo "\n"; } + } if (isset($eplug_js) && $eplug_js) { + echo "\n\n"; if(is_array($eplug_js)) { foreach($eplug_js as $kjs)