From aa998fcc0691391333198b28489a931b5946c91e Mon Sep 17 00:00:00 2001 From: shish Date: Sun, 30 Dec 2007 11:49:58 +0000 Subject: [PATCH] Argh PHP git-svn-id: file:///home/shish/svn/shimmie2/trunk@671 7f39781d-f577-437e-ae19-be835c7a54ca --- ext/load_ext_data/main.php | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/ext/load_ext_data/main.php b/ext/load_ext_data/main.php index f443dd44..e0b216de 100644 --- a/ext/load_ext_data/main.php +++ b/ext/load_ext_data/main.php @@ -6,12 +6,18 @@ class LoadExtData extends Extension { $data_href = get_base_href(); - foreach(glob("ext/*/style.css") as $css_file) { - $page->add_header(""); + $css_files = glob("ext/*/style.css"); + if($css_files) { + foreach($css_files as $css_file) { + $page->add_header(""); + } } - foreach(glob("ext/*/script.js") as $js_file) { - $page->add_header(""); + $js_files = glob("ext/*/script.js"); + if($js_files) { + foreach($js_files as $js_file) { + $page->add_header(""); + } } } }