Start page / Template development / Template syntax / System objects / #docGroup

#docGroupAvailable from FirstSpirit Version 4.0

The system object #docGroup is used within the context of document groups and controls the generation of documents. It refers to the ("virtual") root node of the current document group. Via dot notation it provides various methods with which, for example, a table of contents can be generated.

Important In general system objects can be read-accessed only. However, there are several methods which can also modify system objects or can affect the system performance. These include, e.g. the output of a document group's elements during generation (cf. #docGroup.pageFirst).

In the following the useable method invocations are listed:




Returns a list of the document group's child nodes. Each child is in turn of the same type as #docGroup. The list of children contains nodes of the type "page reference" first, followed by nodes of the type "menu level".


Returns the depth of the node in the document group (e.g. "0" for the highest level). By way of comparison: Nodes of the #docGroup.childs list have depth "1".


Indicates whether the node is of the type "menu level" (value true) or not (value false).


Indicates whether the node is of the type "page reference" (value true) or not (value false).


Returns the node's index in the "childs" list of the parent node.


Returns the parent node of the element. If the docGroup is already the root node null is returned.


Returns the value true, if the node itself or a child node is currently being written in the output.


Returns the heading of the node; for the root this equals the name of the document group, for menu levels the menu name and for page references the sitemap name.


Returns the chapter number, e.g. a text in the form "2.3.1".


Returns the chapter number; however, unlike #docGroup.chapter, with #docGroup.section section only folders are included in the chapter numbering.


Returns the virtual root element (equals the value of #docGroup).


The value should be set to true in the start template (using the expression $CMS_SET(...)$), if pages are to be output before folders. Output within the template can be achieved with the expression $CMS_VALUE(...)$.

Important Further information about working with document groups and examples can be found in the Document groups area.

© 2005 - 2024 Crownpeak Technology GmbH | All rights reserved. | FirstSpirit 2024.4 | Data privacy