/** * Before merge CSS callback function * * @param string $file * @param string $contents * * @return string */ public function beforeMergeCss($file, $contents) { $minContent = $this->useMinifiedVersion($file); if ($minContent !== false) { $contents = $minContent; } $handles = Mage::app()->getLayout()->getUpdate()->getHandles(); $contents = "\n\n/* FILE: " . basename($file) . " */\n/* HANDLES: " . implode(",", $handles) . " */\n" . $contents; return parent::beforeMergeCss($file, $contents); }
/** * Before merge CSS callback function * * @param string $file * @param string $contents * * @return string */ public function beforeMergeCss($file, $contents) { $minContent = $this->useMinifiedVersion($file); if ($minContent !== false) { $contents = $minContent; } $contents = "\n\n/* FILE: " . basename($file) . " */\n" . $contents; return parent::beforeMergeCss($file, $contents); }