Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2010-11-21 03:38:12

M Triplett
New Member
From: Chapel Hill, NC
Registered: 2010-06-01
Posts: 5
Website

using 1 page as a template (or something like that)

wondering if anyone can give me some advice. i have this record label site that i am building out for the client using textpattern as the back-end. There are artist pages that are basically the same but with different content. I know i could create a page for each individual artist but is there a way that i could use 1 page template and the same forms for all the different artist but use categories or sections . if the client wants to add an artist i do not want to have to create the page for him each time. here is an artist page example http://griptapessite.com/veelee.html I’m new but things are finally starting to click but this one has me stuck.

Offline

#2 2010-11-21 21:27:28

THE BLUE DRAGON
Member
From: Israel
Registered: 2007-11-16
Posts: 638
Website

Re: using 1 page as a template (or something like that)

You should build the site when sections (artists/news/tour) are pages, and the contents inside these pages are articles.
That means yes the page it’s the template and the artists are articles.
You can control of how will look the main artists page (artists-list) and how will look the inside page of each artist.

Here’s an simple example using forms:

<txp:article form="artists" listform="artists_list" />

Or specific places inside the page:

<txp:if_article_list>
<txp:article form="artists_list" />
<txp:else />
<txp:article form="artists" />
</txp:if_article_list>

Or as container tags:

<txp:if_article_list>
<ul>
<txp:article>
<li><txp:permlink><txp:title /></txp:permlink></li>
</txp:article>
</ul>
<txp:else />
<txp:article>
<txp:title />
<br /><txp:body />
</txp:article>
</txp:if_article_list>

For more info about the <txp:article /> tag, visit: http://textpattern.net/wiki/index.php?title=article

Offline

Board footer

Powered by FluxBB