Wednesday 04 February 2009 12:51:02 pm
I have an array:
{def $relations=fetch('content','related_objects',hash(object_id,$child.contentobject_id)) }
I want to loop through and show just those items that have the class_identifier I want.
{foreach $relations as $prod}
{if $prod.class_identifier|eq('application')}
{skip}
{/if}
<a href={$prod.main_node.url_alias|ezurl}>{$prod.main_node.name|wash()}</a>
{delimiter}, {/delimiter}
{/foreach}
The problem occurs when it displays on the page as putting the delimiter in after the last entry. I thought the {skip}
would stop that from occurring. Am I missing a trick here or is there a better way to accomplish this?
|