[TYPO3-english] add a div after body containing all content in template

bernd wilke t3ng at bernd-wilke.net
Mon Apr 22 13:35:05 CEST 2013


Am 22.04.2013 13:15, schrieb Francesc Juliana:
> Hello everybody:
> I would like to add a div inside body that contains all content. This div
> will be used to have a diferent color from body and will be smalller than
> body. It must contain all content of page.
> I need to add this div throught a template. I don't use html template .
>
> I thought the code will be something like this:
>
> page.bodyTagCObject.stdWrap="<div>|</div>"
>
> but it doen't work as I expect.
> Anyone knows hot to do it?
>
> Thanks in advance.
> Francesc
>
>

why not wrap the object all your content is included?

page = PAGE
page {
	10 = COA
	10 {
		10 = TEXT
		10.value = <img src="logo.jpg" />
		10.wrap = <div class="header">|</div>

		20 < styles.content.get
		20.wrap = <div class="main">|</div>

		30 =
	}
}

or
page = PAGE
page {
	10 < template.definition
}

you can wrap page.10:

page.10.wrap = <div class="outside"><div class="inside">|</div></div>

or use other wrappings which are defined in stdWrap
e.g.
page.10.outerWrap = <div class="outside">|</div>


there is a lot of wrapping possible.


bernd
-- 
http://www.pi-phi.de/cheatsheet.html


More information about the TYPO3-english mailing list