OpenWGA 7.0 - WebTML reference
WebTML tags » foreach<tml:foreach sortmeta ="meta-field">
Purpose:
Sorts the iteration output by a metadata field
Description:
This is only valid for type="content".
Use this attribute together with sortorder. It specifies the name of a metadata field, whose values will be used for sorting. The output will be sorted by the natural sorting order of the fields values.
Value(s):
Name of the metadata field to sort by
Examples:
This example sorts the output by the documents title:
<tml:collection>
-
<tml:query> ... </tml:query>
-
<tml:foreach sortorder="ascending" sortmeta="TITLE">
- <li><tml:meta name="title"/></li>
-
</tml:foreach>