New Message: Conditional enclosure support

webmaster at userland.com webmaster at userland.com
Sat Jun 3 11:29:54 CDT 2006


A new message was posted:

Address: http://manila.userland.com/discuss/msgReader$1806

By: Matt Deatherage (frontier at gcsf.com)

I know about the "New news item macros: Enclosures" features added a while back, but I can't figure out: can I use them conditionally in a template?

As far as I can tell, the news item framework simply substitutes the values for enclosure names, URLs, icons, etc. when it renders the page. If there is no enclosure, the macros get replaced with "", so nothing shows up.

But suppose, for example, that if an enclosure exists, I want to draw a horizontal line and then say "*Enclosure: *", followed by titles and links and such. As far as I can tell, I can't do that in a way so that this text shows up when an enclosure exists but not otherwise. This makes news item template design a lot more limited - you have to put the enclosure stuff where no one will notice it if it's missing, so you can't call attention to it if it's there.

Am I missing something?

This is a Manila site... http://manila.userland.com/.




More information about the Manila-Users mailing list