You are here:   » Home » Documentation » Details » How-To » TOC-Lists » Home

Presentation of the child objects of the current context

Author: F. Hoffmann, 2003/07/18

The folder page shall end with a list of the site objects beneath in form of a TOC. Besides the document title the attribute value of DC.Description shall be displayed.

Solution: Iteration loop with correspondent HTML sequences for starting and ending the list (sequence-start/end).

<!-- BO bodyContent_Index -->

 <dtml-in "getIndexNavElements(REQUEST)">
  <dtml-if sequence-start>
   <h2>Table of content:</h2>
  </dtml-if>
  <ul>
   <li>
    <a href="<dtml-var "getHref2IndexHtml(REQUEST)">"><dtml-var 
    "getTitle(REQUEST)"></a><br>
    <dtml-var "getObjProperty('attr_dc_description',REQUEST)">
   </li>
  </ul>
 </dtml-in>

<!-- EO bodyContent_Index -->

Comment: An explicit identification of the object type is not needed because a list appears only in case that sub-documents do really exist (meaning the object is type folder).