*Title: TOC operator
*Original author: Bard Farstad
*Documentation:
'eztoc' is a template operator which generates a template table of contents
using the headers in an XML field.
The usage of the operator is as follows:
In the object template:
{* body is ezxml datatype*}
{eztoc( $node.object.data_map.body )}
This will produce the HTML output on the page (170 is an attribute ID):
<ul>
<ul>
<li><a href="#170_1">1. Quisque aliquet</a></li>
<ul>
<li><a href="#170_1_1">1.1 Cum sociis</a></li>
</ul>
</ul>
<ul>
<li><a href="#170_2">2. Quisque aliquet</a></li>
<ul>
<li><a href="#170_2_1">2.1 Cum sociis</a></li>
</ul>
</ul>
</ul>
TOC operator
*Original author: Bard Farstad
Address: https://doc.exponential.earth/exphelp/viewer/features/3.8/TOC_operator.txt
Documentation license
This page was inherited from the documentation of the original software. It is not covered by the GNU Free Documentation License; it is distributed under the GNU General Public License, version 2.
Copyright (C) 1999 - 2014 eZ Systems AS and contributors