【发布时间】:2023-03-31 17:26:01
【问题描述】:
我需要使用 TemplateBeginRepeat 创建 2 个循环,我需要在其中输出自定义标签
<!-- TemplateBeginRepeat name="customtag" -->
${RenderComponentPresentation(Field, rendercustomtagstarttemplate)}
<!-- TemplateEndRepeat -->
输出一些html
<!-- TemplateBeginRepeat name="customtag" -->
${RenderComponentPresentation(Field, rendercustomtagclosetemplate)}
<!-- TemplateEndRepeat -->
由于第二个循环关闭了第一个循环呈现的自定义标记,因此第二个循环应该以相反的顺序运行。 (因为标签需要以相反的顺序关闭)。如何使用 TemplateBeginRepeat 以组件的相反顺序运行第二个循环?
【问题讨论】:
-
customtag是什么类型?它是一个字段吗? -
请注意 ${} 应该只用于例外情况,而不是默认情况下。它允许您在默认 @@ @@ 之前先评估(呈现)表达式。
标签: tridion tridion-2011