Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#16 2005-11-22 06:25:21

thebombsite
Archived Plugin Author
From: Exmouth, England
Registered: 2004-08-24
Posts: 3,251
Website

Re: Use one template for multiple sections

Well it’s an excellent idea if someone has used it, or is it still theory?


Stuart

In a Time of Universal Deceit
Telling the Truth is Revolutionary.

Offline

#17 2005-11-22 07:03:08

maniqui
Member
From: Buenos Aires, Argentina
Registered: 2004-10-10
Posts: 3,070
Website

Re: Use one template for multiple sections

> thebombsite wrote:

> Well it’s an excellent idea if someone has used it, or is it still theory?

Stuart, do you mean if someone has used <div id="<txp:section />">?

I have used it sometimes in <body id="<txp:section />"> (long time ago, in the days of RC1, to achieve a way to style the current section link in the main menu).

Another interesting place to put it is in a “div” surrounding your article layout.
I mean:

<div class="article <txp:section />">
<h3><txp:title /></h3>
more article tags
blablab
</div>

This way, you can give unique styles to your articles, depending on the section it belongs to.

Last edited by maniqui (2005-11-22 14:30:37)


La música ideas portará y siempre continuará

TXP Builders – finely-crafted code, design and txp

Offline

#18 2005-11-22 07:32:08

thebombsite
Archived Plugin Author
From: Exmouth, England
Registered: 2004-08-24
Posts: 3,251
Website

Re: Use one template for multiple sections

I was just wondering if it had actually been tried and works. If you’ve used it then great! Go to the top of the class! :)


Stuart

In a Time of Universal Deceit
Telling the Truth is Revolutionary.

Offline

#19 2005-11-22 08:28:58

nardo
Member
From: tuvalahiti
Registered: 2004-04-22
Posts: 743

Re: Use one template for multiple sections

for sure stuart … it’s become a habit to throw the section name as an id into the body tag, so you can override styles for specific sections (e.g. contact forms vs navigation pulldowns)

also u can change widths on divs depending on the section … very handy if you have some sections with one column, some with two, some with three, etc : )

Offline

Board footer

Powered by FluxBB