[BUGFIX] Correct Path Calculation in Cardlayout
authorKay Strobach <typo3@kay-strobach.de>
Sun, 22 Apr 2012 10:09:02 +0000 (12:09 +0200)
committerChristian Kuhn <lolli@schwarzbu.ch>
Mon, 18 Jun 2012 20:51:19 +0000 (22:51 +0200)
Fixes absolute path calculation bug and introduces the correct
relative calculation similar to jsFiles.

Change-Id: If7b41c9aa26f7b60cceae9ae680d94a257308df8
Fixes: #36308
Releases: 6.0, 4.7
Reviewed-on: http://review.typo3.org/10689
Reviewed-by: Tolleiv Nietsch
Tested-by: Tolleiv Nietsch
Reviewed-by: Stefan Neufeind
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
typo3/backend.php

index c313104..589d20e 100644 (file)
@@ -818,7 +818,9 @@ if (is_array($GLOBALS['TBE_MODULES']['_configuration'])) {
        foreach ($GLOBALS['TBE_MODULES']['_configuration'] as $moduleConfig) {
                if (is_array($moduleConfig['cssFiles'])) {
                        foreach ($moduleConfig['cssFiles'] as $cssFileName => $cssFile) {
-                               $TYPO3backend->addCssFile($name, t3lib_div::getFileAbsFileName($cssFile));
+                               $files = array(t3lib_div::getFileAbsFileName($cssFile));
+                               $files = t3lib_div::removePrefixPathFromList($files, PATH_site);
+                               $TYPO3backend->addCssFile($cssFileName, '../' . $files[0]);
                        }
                }
                if (is_array($moduleConfig['jsFiles'])) {
@@ -835,4 +837,4 @@ $TYPO3backend->render();
 
 Typo3_Bootstrap::getInstance()->shutdown();
 
-?>
\ No newline at end of file
+?>