[Typo3] [TYPO3] How can I reduce html in typoscript

Christopher bedlamhotel at gmail.com
Sat Oct 22 07:18:22 CEST 2005


Hi,

On 21/10/05, Dennis Cheung <hkdennis2k at gmail.com> wrote:
> Hi all,
> I am new to typo3. And started to write my first typo3 template.
>
> But I've a question, in the tutor, they use a lot warp=xxx | yyy to make it
> works.
> Even I am using template, there are still some parts need leave within the
> script.
> (e.g. I want to specifiy a different table of "each column"
> styles.content.getRight)
>
> I don't want so much html within the script, I want them on the template
> file.
> So it will be easier to edit, preview and debug.
>
> I was looking for one of the following...
> 1. like the "tt_news" template, can I reuse a subpart and apply to my code~?
> 2. can I read text from a file, and apply them to the "xxx.wrap=" ? (I still
> can use ssi)
>
> But none useful information found.
>
> Now, I has to hardcode of the table within typoscript using a lot wrap for
> the columns(I don't know how typo3 call it, a "New Content" in
> "pagecontent")
> and for the TMENU,
>
> Can I wrote everything in HTML, and let it learn from them? Like tt_news
> template did.
>

Michael's advice -- to go through the MTB tutorial -- is good, but you
should remember that, since Typo3's html templates contain no logic
(if - then - else and such), you are always going to have some markup
embedded in Typoscript.

This applies, for example, to menus and any item whose display is
conditional (e.g. "imageWrapIfAny" in tt_news), but most anything else
you should be able to retain within the template.

-Christopher



More information about the TYPO3-english mailing list