Monday 02 May 2005 6:11:07 am
Using this code from http://www.ez.no/ez_publish/documentation/customization/tips_tricks/one_article_folder
{* Get the articles (ClassID: "2"! Might be different for you!) *}
{let articles=fetch('content','list',hash(parent_node_id,$node.node_id,class_filter_type,"include",class_filter_array,array(2)))}
{* Get a count of the articles (ClassID: "2"! Might be different for you!) in this folder. *}
{let articles_count=fetch('content','list_count',hash(parent_node_id,$node.node_id,class_filter_type,"include",class_filter_array,array(2)))}
{* Now decide what to do *}
{switch name=decision match=$articles_count}
{case match=1}
{* Show this if there is only one article! E.g. include the "full article view" page. *}
{section name=Article loop=$articles}
{node_view_gui view=full content_node=$decision:Article:item}
{/section}
{/case}
{case}
{* Show this for more than one article. *}
{section name=Article loop=$articles}
<h3>{$decision:Article:item.name}</h3>
{$decision:Article:item.data_map.intro.data_text}<br /><br />
{section name=read_link show=$decision:Article:item.contentobject_version_object.data_map.body}
<a href={concat("/content/view/full/",$decision:Article:item.node_id)|ezurl}>Read more...</a>
{/section}
<hr />
{/section}
{/case}
{/switch}
The problem is that if its just one article in the folder, it's not using my template overides. If there is two or more, this code list's it up and then uses my full_view template overide when you click one.
<a href={concat("/content/view/full/",$decision:Article:item.node_id)|ezurl}>Read more...</a>
This code is the one that uses my template overides, prob. since it's calling content/view/full, and I've modified that. then why doesn't this do the same???:
{section name=Article loop=$articles}
{node_view_gui view=full content_node=$decision:Article:item}
{/section}
please help........
|