[TYPO3-performance] Typoscript with conditions or ext template on page

Michiel Roos [netcreators] michiel at netcreators.com
Tue Dec 15 15:55:17 CET 2009


Op 12/15/09 1:42 PM, Martin Kutschker schreef:
> Mathias Schreiber [wmdb >] schrieb:
>> Sven Wolfermann schrieb:
> 
>>> sample constants condition:
>>>
>>> [PIDinRootline = 703]
>>> homeID = 703
>>> catId = 1,6,18
>>> showListId = 946
>>> showEventId = 945
>>> newsSingle = 3343
>>> newsFolder = 353,248,53
>>> plugin.tx_cal_controller.pidList = 2476,1457,1954
>>> [end]
>>
>> Ext Templates are faster, since conditions are parsed (uncached) at any
>> page request.
>>
>> Drawback:
>> A lot of things are only possible with conditions AND ext Templates are
>> a bit more "chaotic" to find.
>> Basically I like to keep my stuff at one place only.
> 
> A matter of taste. I don't like PIDinRootline at all. PIDs mean nothing to me (without a further
> comment in the TS) when I try to understand the TS code. So I prefer ext templates for branches.
> 
> Masi

We use constants instead of PIDs.

On the template in the site root we have the constants:

newsPage       = 1
newsSinglePage = 2
someOtherPage  = 3

And then in the ext templates we use those constants in the conditions.

We don't like spreading templates across the whole tree.

-- 

Met vriendelijke groet / Warm regards,


Michiel Roos
TYPO3 Developer
Certified TYPO3 Integrator

t. 06 458 7 8 9 10
w. netcreators.com
_____________________________________________
Netcreators: Open Source, Open Minds, Open People
_____________________________________________

TYPO3 Developer gezocht, lees de vacature online:
http://www.netcreators.com/bedrijf/vacatures-typo3-developer/


More information about the TYPO3-performance mailing list