Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Multiple Excerpts (*not* custom fields)
Evening TXP experts!
I’ve tried to search for this, but didn’t find anything of help. I’d like to get multiple excerpts per post (which will be multiple testimonials per wedding, plus my own synopsis of the wedding).
Custom fields are awkward because they’re limited in size with regards to both input length (although I remember that one can update the data type via MySQL, although I’ve forgotten how to do this!), and back-end input (tiny input boxes).
Is there a plugin, or method, to accomplish this?
Any help would be appreciated!
Offline
#2 2012-05-10 18:41:26
- GugUser
- Member
- From: Quito (Ecuador)
- Registered: 2007-12-16
- Posts: 1,477
Re: Multiple Excerpts (*not* custom fields)
May be glz_custom_fields can help.
Offline
Re: Multiple Excerpts (*not* custom fields)
yeah, glz let’s you add textareas as CFs.
Offline
Re: Multiple Excerpts (*not* custom fields)
Thanks very much!
I’ll give that a go, looks promising :¬)
Offline
Re: Multiple Excerpts (*not* custom fields)
While glz_cf is great, you would need to reserve CFs for this purpose so that limits the maximum number of testimonials you can have per article. If that’s not a problem, then cool.
Other options you may wish to explore:
- Links. Create each testimonial as a Txp Link in a ‘testimonials’ Link category. The description can be the testimonial itself; the title can be the name of the person who wrote it. In either the URL or the sort order, store a reference to the article it relates to: either the article ID or its url-title. You can then filter the Links using
<txp:linklist>
and some conditional logic in the container to only pull out records that match the current article. Or if that sounds slow/ too much hassle, create a Link category per wedding that matches the url-title and stick the relevant testimonials in that category, then use<txp:linklist category='<txp:article_url_title />' />
in your article Form to grab and show them. - Comments (shiver). Gather / store testimonials as article comments and use Txp’s comment tags to display them associated with an article. You can do this with a special login if you wish so clients can add them from the public site, or bounce them to an smd_tabber dashboard which acts as a simplified interface to the comments area.
Some creativity might be required in either approach and if you’re handing this over to a client it may require some theme alterations to streamline the workflow, but both options give you potentially unlimited number of testimonials per article.
Last edited by Bloke (2012-05-10 19:42:47)
The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.
Txp Builders – finely-crafted code, design and Txp
Offline
Re: Multiple Excerpts (*not* custom fields)
Styled links, linked to articles… that’s ingenious!
I’ll most certainly look into that, I was already wondering how the post+author could be differentiated using custom fields.
Thanks – great idea!
Offline