From 1da545418e4e785cfa5029ebc7c619c9a7ce40ef Mon Sep 17 00:00:00 2001 From: Petr Skoda Date: Tue, 5 Jan 2010 00:19:50 +0000 Subject: [PATCH] MDL-20204 removing duplicate YUI skin CSS, thanks Sam for noticing it --- lib/outputlib.php | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/lib/outputlib.php b/lib/outputlib.php index 65792f291c..983354cfcb 100644 --- a/lib/outputlib.php +++ b/lib/outputlib.php @@ -642,19 +642,7 @@ class theme_config { // legacy YUI2 stylesheets, YUI3 stylesheets are loaded on the fly $yui2_sheets = "\n\n/*** Standard YUI2 sheets ***/\n\n"; - $items = new DirectoryIterator("$CFG->libdir/yui/$CFG->yui2version/build/assets/skins/sam"); - foreach ($items as $item) { - if ($item->isDot() or !$item->isFile()) { - continue; - } - $filename = $item->getFilename(); - if (substr($filename, -4) !== '.css') { - continue; - } - $yui2_sheets .= file_get_contents("$CFG->libdir/yui/$CFG->yui2version/build/assets/skins/sam/$filename"); - } - unset($item); - unset($items); + $yui2_sheets .= file_get_contents("$CFG->libdir/yui/$CFG->yui2version/build/assets/skins/sam/skin.css"); // search for all images in yui2 CSS and serve them through the yui_image.php script $css['yui2'][] = preg_replace('/([a-z-]+)\.(png|gif)/', 'yui_image.php?file='.$CFG->yui2version.'/$1.$2', $yui2_sheets); -- 2.39.5