Forums / Setup & design / How to display node names of my relation list?

How to display node names of my relation list?

Author Message

Ulrich L.

Thursday 10 March 2005 12:08:42 pm

Hi,
I've written the following code, and I was quite sure it should work. While the nodeID is indicated correctly, the output of node.name remains empty. Why...?

{section name=myloop loop=$node.data_map.artist_instrument.content.relation_list}
INDEX {$myloop:index}
NODE_ID {$myloop:item.node_id}
NAME {$myloop:item.name}
{delimiter}, {/delimiter}
{$myloop:item|attribute(show)}
{/section}

The attribute(show) command displays the following attributes for an example object:
priority string 1
contentobject_id string 89
contentobject_version string 1
node_id string 90
parent_node_id string 78
contentclass_id string 24
contentclass_identifier string 'general_instrument'
identifier boolean false
is_modified boolean false

That's all.
Please help me, I'm already quite desperated...

Ɓukasz Serwatka

Friday 11 March 2005 3:41:55 am

Hi Uli,

This should help

{section var=Relations loop=$node.object.data_map.artist_instrument.content.relation_list}
    {content_view_gui view=text content_object=fetch( content, object, hash( object_id, $Relations.item.contentobject_id, object_version, $Relations.item.contentobject_version ) )}<br />
{/section}

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog

Ulrich L.

Friday 11 March 2005 6:42:29 am

Thanks, Luke. I understand now a fetch command is required anyway.