[TYPO3] Section index and option split

Tapio Markula tapio.markula at atwebteam.com
Mon May 14 19:07:33 CEST 2007


Tyler Kraft kirjoitti:
> Joey,
> 
> Thanks for reposting this! Very handy to have.
> 
> Ty
> 
> 
> JoH asenau wrote:
>>>> sorry I was wrong, not Joey but Bernhard...  It was probably
>>>> kb_betterstdwrap that I'm thinking of.
>>> ok Endeed I would be delighted if I could get some advice how to
>>> do that using CASE/if and LOAD_REGISTER
>>
>> You don't need them at all.
>> Use split instead, which will give you the optionSplit you wanted.
>> All you have to do is create a "splitter" in the output of your CONTENT
>> element.
>> Don't remember when I posted this the first time so here is a small 
>> example
>> similar to the one we are using in the cookbook:
>>
>> 10 = COA
>> 10 {
>>     10 = CONTENT
>>     10 {
>>         table = blah
>>         select {
>>             #blah
>>         }
>>         renderObj = COA
>>         renderObj {
>>             # blah
>>             wrap = |###SPLITTER###
>>         }
>>     }
>>     stdWrap.split {
>>         token = ###SPLITTER###
>>         cObjNum = 1 || 2 |*| 3 || 4 |*| 5 || 6
>>         1.current = 1
>>         1.wrap = <div class="wrap1">|</div>
>>         2.current = 1
>>         2.wrap = <div class="wrap2">|</div>
>>         3.current = 1
>>         3.wrap = <div class="wrap3">|</div>
>>         4.current = 1
>>         4.wrap = <div class="wrap4">|</div>
>>         5.current = 1
>>         5.wrap = <div class="wrap5">|</div>
>>         6.current = 1
>>     }
>> }
>>
>> This will wrap ten entries like this:
>>
>> wrap1, wrap2, wrap3, wrap4, wrap3, wrap4, wrap3, wrap4, wrap3, wrap5

I don't understand the result (in the middle 'wrap3, wrap4') . In fact I 
would need just first, middle, last - what could be the minimum wrap set?

I got desired result with Peter Klein's way but that might be simpler.


More information about the TYPO3-english mailing list