This tag is not standard HTML, was created using marking components such as the documentation of the Freemarker explains.
Answering your question:
You use FTL tags to call directives. In the example, you called the listdirective. Syntactically you did it with two tags: <#list (pageRender.getInstancesIds("SlotB"))! as id>
and </#list>
.
There are two types of FTL tags:
Start-tag: <#directivename parameters>
Final tag: </#directivename>
This is similar to HTML or XML syntax, except for the name of the tag that starts with #. If the directive has no nested content (content between the initial tag and the final tag), you should use the initial tag without the final tag. For example, you write <#if something>...</#if>
, but so <#include something>
Freemarker knows that the include
cannot have a nested content.
The format of Parameters depends on the directive.
In fact, there are two types of directives: predefined directives and user-defined directives . For user-defined directives, you use @
instead of #
, for example <@mydirective parameters>...</@mydirective>
. Another difference is that if the directive has no nested content, you should use a tag like <@mydirective parameters />
, in the same way as in XML (for example <img ... />
).
Tags FTL, as tags HTML, should be nested correctly. Therefore, the code below is wrong, because the ifdirective is inside and outside the nested content of the directive list:
<ul>
<#list animals as animal>
<li>${animal.name} for ${animal.price} Euros
<#if user == "Big Joe">
(except for you)
</#list> <#-- WRONG! The "if" has to be closed first. -->
</#if>
</ul>
References in:
TOTVS? http://tdn.totvs.com/pages/releaseview.action?pageId=113803693
– Laércio Lopes
It’s from Apache Freemaker <#list>.
– Augusto Vasques