[TYPO3-project-4-3] CSS and JS files get included in the wrong order if using the page-renderer
Thomas "Thasmo" Deinhamer
thasmo at gmail.com
Sat Nov 14 01:49:26 CET 2009
Did you investigate this already; is it a bug?
Thank you! =o)
Steffen Kamper schrieb:
> Susanne Moog schrieb:
>
>> $GLOBALS['TSFE']->getPageRenderer()->addCssFile('typo3conf/ext/....css');
>>
>> and in TS
>>
>> page.includeCSS.file1 = fileadmin/css/reset.css
>> page.includeCSS.file1.forceOnTop = 1
>>
>> Output is first typo3conf/ext... then fileadmin/css/reset.css
>>
>
> that's not correct, looks buggy. i will debug, and if it's a bug i will
> fix.
>
>> If I debug the $this->cssFiles array in the pagerenderer it shows that
>> forceOnTop is set correctly but has no effect on the order at all.
>>
>>
>>> If you can't achieve it that way you could use the concatenateHandler to
>>> sort the array for your need. Maybe we need a renderHook as well.
>>
>> I'll have a look into it later.
>>
>
> it's the wrong place, as the hook is no array, so you can't use more
> than one extension using this hook (it' only the last chance to change)
>
>> Perhaps we could have an additional key, string, whatever, to sort by,
>> so that I could define, ok, reset is "a", extension is "b", common.css
>> is "c" and so on...
>>
>
> i don't think that is needed really, but maybe a sorting option for the
> associative array.
>
> vg Steffen
More information about the TYPO3-project-4-3
mailing list