Forums / Developer / List related objects?
Clemens T
Saturday 01 October 2005 6:21:52 am
Heya all, There is a fetch for reverse_related_objects, but how about just related objects? How can I display them in my templates? Thanks,Clemens
Saturday 01 October 2005 6:25:33 am
Never mind, got it (from the admin tpl)
... {section show=$node.object.related_contentobject_count} {section var=RelatedObjects loop=$node.object.related_contentobject_array sequence=array( bglight, bgdark )} <tr class="{$RelatedObjects.sequence}"> {* Name. *} <td>{$RelatedObjects.item.content_class.identifier|class_icon( small, $RelatedObjects.item.content_class.name|wash )} {content_view_gui view=text_linked content_object=$RelatedObjects.item}</td> {* Type. *} {section show=$node.object.related_contentobject_count} <td>{$RelatedObjects.content_class.name|wash}</td> {/section} </tr> {/section} ...