From: Michael J. Rubinsky Date: Fri, 21 Jan 2011 16:11:05 +0000 (-0500) Subject: Output full uris for stylesheets when rendering via API X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=f9488bf92087ac71d7affbaa849d8d0435c98a99;p=horde.git Output full uris for stylesheets when rendering via API --- diff --git a/ansel/lib/View/EmbeddedRenderer/GalleryLink.php b/ansel/lib/View/EmbeddedRenderer/GalleryLink.php index c2e5b5ccc..7c1569a59 100644 --- a/ansel/lib/View/EmbeddedRenderer/GalleryLink.php +++ b/ansel/lib/View/EmbeddedRenderer/GalleryLink.php @@ -88,7 +88,7 @@ class Ansel_View_EmbeddedRenderer_GalleryLink extends Ansel_View_Gallery Horde::includeStylesheetFiles(array( 'nobase' => true, 'nohorde' => true - )); + ), true); $css = Horde::endBuffer(); /* Some paths */ diff --git a/ansel/lib/View/EmbeddedRenderer/Mini.php b/ansel/lib/View/EmbeddedRenderer/Mini.php index 07d0662c4..c06e1d823 100644 --- a/ansel/lib/View/EmbeddedRenderer/Mini.php +++ b/ansel/lib/View/EmbeddedRenderer/Mini.php @@ -97,7 +97,7 @@ class Ansel_View_EmbeddedRenderer_Mini extends Ansel_View_Gallery Horde::startBuffer(); Horde::includeStylesheetFiles(array( 'nobase' => true - )); + ), true); $css = Horde::endBuffer(); /* Start building the javascript */ diff --git a/ansel/lib/View/GalleryRenderer/GalleryLightbox.php b/ansel/lib/View/GalleryRenderer/GalleryLightbox.php index a298e1d52..13b62b3b9 100644 --- a/ansel/lib/View/GalleryRenderer/GalleryLightbox.php +++ b/ansel/lib/View/GalleryRenderer/GalleryLightbox.php @@ -136,7 +136,7 @@ class Ansel_View_GalleryRenderer_GalleryLightbox extends Ansel_View_GalleryRende /* Output js/css here if we are calling via the api */ if ($this->view->api) { $GLOBALS['injector']->getInstance('Horde_Themes_Css')->addThemeStylesheet('lightbox.css'); - Horde::includeStylesheetFiles(array('nobase' => true)); + Horde::includeStylesheetFiles(array('nobase' => true), true); $includes = $GLOBALS['injector']->createInstance('Horde_Script_Files'); $includes->add('accesskeys.js', 'horde', true); $includes->add('effects.js', 'horde', true); diff --git a/framework/Core/lib/Horde.php b/framework/Core/lib/Horde.php index 5012fd4ae..8eed79434 100644 --- a/framework/Core/lib/Horde.php +++ b/framework/Core/lib/Horde.php @@ -1416,11 +1416,13 @@ HTML; * * @param array $opts Options to pass to * Horde_Themes_Css::getStylesheetUrls(). + * + * @param boolean $full Output full uris. */ - static public function includeStylesheetFiles(array $opts = array()) + static public function includeStylesheetFiles(array $opts = array(), $full = false) { foreach ($GLOBALS['injector']->getInstance('Horde_Themes_Css')->getStylesheetUrls($opts) as $val) { - echo ''; + echo ''; } }