Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
making good progress
I think I’m starting to get to grips with TXP now which is great.
Learning curve is similar to Expression Engine (I know I keep barking on about it but it’s what I know).
I have another question which should be a relative quick hitter.
On my site’s homepage I want to pull in my latest project from my client section and my latest entry from my blog section.
Now I used <txp:article_custom id=“2” pgonly=“0” /> which displays my client project by id. That of course renders the following:
<h3 class=“entry-title”><a rel=“bookmark” href=“http://digitalevangelist.net/work/2/greenview-evangelical-church”>Greenview Evangelical Church</a></h3>
<p class=“published”>5 days ago</p>
<div class=“entry-content”> <p>Velit esse cillum dolore sed do eiusmod tempor incididunt quis nostrud exercitation. Lorem ipsum dolor sit amet, eu fugiat nulla pariatur. Consectetur adipisicing elit, qui officia deserunt sunt in culpa.</p>
<p>Quis nostrud exercitation velit esse cillum dolore ut aliquip ex ea commodo consequat. Ut enim ad minim veniam, ut labore et dolore magna aliqua. Excepteur sint occaecat sunt in culpa ullamco laboris nisi. Velit esse cillum dolore. Ut enim ad minim veniam, excepteur sint occaecat lorem ipsum dolor sit amet.</p>
<p>Velit esse cillum dolore quis nostrud exercitation sed do eiusmod tempor incididunt. Qui officia deserunt excepteur sint occaecat ut labore et dolore magna aliqua. Velit esse cillum dolore ut aliquip ex ea commodo consequat. Cupidatat non proident, ut enim ad minim veniam, duis aute irure dolor.</p>
<p>Sunt in culpa excepteur sint occaecat ut aliquip ex ea commodo consequat. Ut aliquip ex ea commodo consequat. Eu fugiat nulla pariatur. Duis aute irure dolor cupidatat non proident, velit esse cillum dolore. Mollit anim id est laborum.</p>
</div>
<address class=“vcard author”>— <span class=“fn”>Steven Grant</span></address>
<p class=“tags”>, </p>
<div class=“divider”><img src=“http://digitalevangelist.net/images/1.gif” width=“400” height=“1” alt=”—-” title=”“ /></div>
How can I change that so that I can control what heading style is used and how I can drop off the other information that I don’t need?
Thanks,
Steven
Offline
Re: making good progress
The article_custom tag will use the default form is no form attribute is assigned, so if you wish to use a different form, then use something like:
<txp:article_custom id=“2” form="my-form" />
Obviously you need to create the form ;-)
You may also use the tag as a container tag like so:
<txp:article_custom id=“2”>
<p><txp:permlink><txp:title /></txp:permlink></p>
</txp:article_custom>
So, use either a form or the contents of your form within a container tag.
Offline
Re: making good progress
Thanks jstubbs – that really helps.
I’m getting there – albeit slowly :-)
Offline
Pages: 1