Monday 04 October 2004 4:56:18 am
I handled the related items this way:
{let related=$node.object.data_map.keywords.content.related_objects}
{section show=$related}
{switch match=$related}
{case match=''}
{/case}
{case}
<h3>Related documents</h3>
{/case}
{/switch}
<ol>
{section name=Related loop=$related}
<li class="relateditem"><a href={$:item.url_alias|ezurl}>{$:item.name}</a> <span class="relateditemclass"><nobr>{$node.object.class_name|wash}</nobr></span></li>
{/section}
</ol>
{/section}
{/let}
This tells the section title (related objects) to display only if there are items under it. Another way to do it would be to repeat your fetch for related items but substitute list_count for list, and assign that to a variable.
...count=fetch('content','list_count',hash(parent_node...
This will return the total number of items that match the fetch criteria which you can use in a section show command.
http://www.thinkcreative.com
Turning Ideas Into Strategic Solutions
|