Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#1 2006-01-21 07:05:53
- takshaka
- Plugin Author
- From: Below the Manson-Nixon line
- Registered: 2004-06-02
- Posts: 97
- Website
[plugin] [ORPHAN] chh_if_data
This tag may be used to determine whether some contained Txp tags output any data, allowing the conditional output of accompanying static markup, like a header or a “no articles found” message.
<txp:chh_if_data>
<h3>Here's an article list</h3>
<txp:article_custom category="Nogo" />
<txp:else />
<p>article_custom had nothing to say.</p>
</txp:chh_if_data>
Offline
#2 2006-01-21 10:34:21
- nardo
- Member
- From: tuvalahiti
- Registered: 2004-04-22
- Posts: 741
Re: [plugin] [ORPHAN] chh_if_data
man you’re on fire!
thank you
Offline
#3 2006-01-21 10:35:26
- Jeremie
- Member
- From: Provence, France
- Registered: 2004-08-11
- Posts: 1,578
- Website
Re: [plugin] [ORPHAN] chh_if_data
Yesss ! Thanks, a lot.
Offline
#4 2006-01-21 10:52:15
- lee
- Member
- From: Normandy, France
- Registered: 2004-06-17
- Posts: 831
Re: [plugin] [ORPHAN] chh_if_data
Very smart and useful. Thanks.
Offline
#5 2006-01-21 15:06:51
- maharis
- New Member
- From: KL Malaysia
- Registered: 2005-08-02
- Posts: 9
- Website
Re: [plugin] [ORPHAN] chh_if_data
most useful plugin to come out this year (so far), thanks! :)
Offline
#6 2006-01-21 23:21:12
- MacStansbury
- New Member
- From: Georgia
- Registered: 2004-12-26
- Posts: 6
- Website
Re: [plugin] [ORPHAN] chh_if_data
this solves something that I’ve been wishing I’d thought of for a while now. when you have no results for a search, it outputs a blank page. now, when there’s no matching keywords from a search, I can put in there:
No Search Results Found
Please try another search
just wrap it around the if_individual_article txp tag. thanks!
Fine then, I’ll just make a hit counter myself.
Offline
#7 2006-01-23 16:20:29
- The-Exit
- Member
- From: Berlin
- Registered: 2005-07-16
- Posts: 175
- Website
Re: [plugin] [ORPHAN] chh_if_data
Thank you for this lovely plugin!
Offline
#8 2006-02-01 06:29:59
- wet
- Developer
- From: Lenzing, Austria
- Registered: 2005-06-06
- Posts: 3,267
- Website
Re: [plugin] [ORPHAN] chh_if_data
Thanks, definitely useful. I employ it to conditionally show article thumbs or a neutral placeholder image depending on their presence.
Robert
Me | f/rwetzlmayr | Repos
Offline
#9 2006-02-07 23:23:24
- Dragan
- Member
- From: Novi Sad, Serbia
- Registered: 2005-10-26
- Posts: 100
- Website
Re: [plugin] [ORPHAN] chh_if_data
I wanted to use this plugin to control the output the category links, because when I don’t assign a category2 it outputs an empty a
element, and I don’t want that to happen.
So I need something along these lines: if there is a category2 assigned output it, if there isn’t, output nothing. Can this be done?
Offline
#10 2006-02-12 16:32:09
- Freshmango
- New Member
- From: Braunschweig, Germany
- Registered: 2004-06-14
- Posts: 7
- Website
Re: [plugin] [ORPHAN] chh_if_data
Very, very useful. But it breaks (for me) with your <code>chh_related_articles</code> plugin.
This is my code:
<code>
<txp:chh_if_data>
<div class=“events”>
<h3>Aktuelle Termine von <txp:title /></h3>
<ul>
<txp:chh_related_articles form=“event” time=“future” relation=“keywords” section=“Veranstaltungen” custommode=“list” />
</ul>
</div> <!— /.events —>
<txp:else />
<p>Zur Zeit liegen uns keine Termine vor.</p>
</txp:chh_if_data>
</code>
Ahhh, wait …. I see … ;-)
I use two TXP-Tags inside <code>chh_if_data</code>. May be there could be something like this:
<code><txp:chh_if_data tag=“chh_related_articles”></code>
But even without this, it is a useful plugin. Thanks for this.
Last edited by Freshmango (2006-02-12 16:50:05)
<a href=“http://dennisfrank.info” title=“Dennis Frank gestaltet – Portfolio” style=“display: block; background:#efefef; color: #545454; float: left; padding: .5em; border: 1px none #9f9f9f; text-decoration: none;”><span style=“border-bottom: 1px solid #9f9f9f;”>Dennis Frank portfolio</span></a>
Offline