[Typo3] manipulate contentelements by TS

JoH info at cybercraft.de
Mon Nov 14 17:59:22 CET 2005


>>>> "you want for each and every "Text w/image" and "image" element or
>>>> if it is just used for special cases."
>>>>
>>>> Thats why I wanted to do the thing by an extension template for one
>>>> special page, where thet template would work for the special page
>>>> and all subpages.
>>>>
>>>> To answer your question, I want it to work just on special pages
>>>> *not* global for all the sites.
>>>
>>> Only for special pages and only for text with image!
>>> Thanks!
>>>  =)
>>
>> OK - basically it's just emptying the original setup and then
>> creating your own instead.
>> But then again it's a bit tricky since we will be using the
>> TS-Element TEXT to get the images out of the "image" field.
>>
> [ ... script ... ]
>> Tested and working ...
>> Have fun with it.
>
> I have to tell you *you are great* !
> =)

Thanks for the flowers ;-)

> To achieve this what you wrote - for me it was like Himalaya -  I
> couldn't get through, not even thinking of getting over!

After all it's all in the TSref. You will need some time to get behind the
"magic" but it's worth the efforts.

> I really apprciate your help!
>
> P.S. Is it also possible with this script to wrap the text part with
> on <p>|</p>?

Of course.
Simply replace this one:

20 < tt_content.text.20

with this code

20 = TEXT
20.field = bodytext
20.wrap = <p>|</p>

But then you should not use the RTE for mor than just plain text _and_ you
will not get "soft linebreaks" with SHIFT+ENTER anymore.

Joey

-- 
Wenn man keine Ahnung hat: Einfach mal Fresse halten!
(If you have no clues: simply shut your knob sometimes!)
Dieter Nuhr, German comedian
openBC: http://www.openbc.com/go/invuid/Jo_Hasenau





More information about the TYPO3-english mailing list