[Zope] Re: Variable name of the ZOPE root? For use in TREE

Kevin Howe khowe@performance-net.com
Fri, 21 Apr 2000 15:13:48 -0300


Hi, figured it out:


If you try to use PARENTS[-1] directy it doesn't work:

Example:
        <!--#tree "PARENTS[-1]" branches_expr="objectValues()" sort=id-->


but if you put it into a variable and then call the variable, it works:

Example:
        <!--#call "REQUEST.set( 'ZopeRootObject' , PARENTS[-1] )"-->

        <!--#tree ZopeRootObject branches_expr="objectValues()" sort=id-->

Strange.
kh



----- Original Message -----
From: "Kevin Howe" <khowe@performance-net.com>
To: "ZOPE Mailing List" <zope@zope.org>
Sent: Friday, April 21, 2000 1:53 PM
Subject: Variable name of the ZOPE root? For use in TREE


> Hi All,
>
> I have created a method using the DTML-TREE tag to create a browsable tree
> starting at the ZOPE root.  My problem is that I don't know how to
> call/refer to the ZOPE root folder.
>
> Ex: The following creates a tree starting with the "QuickStart" tutorial
> folder.
>
> <!--#tree QuickStart branches_expr="objectValues('Image') or
objectValues()"
> sort=id-->
>
> I want to start at the ZOPE root instead, so it should look something like
> this:
>
> <!--#tree ZopeRoot branches_expr="objectValues('Image') or objectValues()"
> sort=id-->
> ...
> <!--#/tree-->
>
> But "ZopeRoot" of course is not the variable name. I have tried "root", a
> blank value (""), a period (".") but none of these work. What is the
> appropriate variable name of the Zope root?
>
> Thanks,
> kh
>
>
>
>
>