[TYPO3] Parsing CSS files - is it possible?
Johannes Reichardt
typo3 at gramba.de
Wed May 24 03:21:01 CEST 2006
Hi Joey,
> Sorry? - What is so complex about 15 lines of TypoScript?
> IMHO it's absolutely easy to understand and to implement this snippet, since
> it works _exactly_ like the rest of the templating stuff.
>
yeah - but only *after* i read it. i prefer php for dynamic things ;)
> If this is what _prevents_ people from using TYPO3, I wonder what we should
> do to get them back.
>
do not use typoscript for programming ;)
> What would be their way of solving problems like this one?
>
> BTW: Do you know a better solution, that is as easy to code and implement?
>
the actual scenario is not so clear to me but to my understanding that
could do it:
$GLOBALS['TSFE']->additionalHeaderData[$this -> prefixId] =
'<style>#bla.background { background: url('.getBGImage($path).'; }</style>';
getBGImage($path) {
simple switch looking for the path and returning image name here...
}
that way you have only one stylesheet and simply override the style
declaration that is necessary.
if thats silly please forgive me - its very late an i just fiddled
without many success on htmlarea configurations for the last few hours ;)
- Johannes
More information about the TYPO3-english
mailing list