[Zope] How to list subfolders of any folder in DTML?

Dieter Maurer dieter@handshake.de
Mon, 10 Mar 2003 22:19:39 +0100

Michael Fox wrote at 2003-3-10 13:20 +1100:
 > ...
 > I have a DTML Method in my Folder A named "listSubfolders" which contains the following code:
 > <dtml-in "objectItems(['Folder'])" sort="id" skip_unauthorized>
 >   <li><a href="&dtml-absolute_url;"><dtml-var title_or_id></a></li>
 > </dtml-in>
 > I want the ability to call this object in any one index_html (DTML Document) within any one folder, to create some sort of navigation of it's subfolders. eg.

Why must your "index_html" be a DTML Document? Make it 
a DTML Method and you can use "listSubfolders" as you want.

In general, forget about DTML Document unless you really
know why you want to use it.