[Zope] Calling object from ZPT

hans hans@beehive.de
Tue, 04 Jun 2002 11:00:12 +0100


Nico de Boer wrote:

> Hi all,
>
> For my Newsproduct I want to call a navigation menu. For my websites I
> allways use NFGNav, so I want to call NFGNav from my Zope Page
> Template.
>
> This is the layout of the site:
>
> 0       1       2
>
> Root -  nfgnav
>         News -  ZPT
>                 News
>                 News
>
> So my ZPT is used for the rendering of the parents News object (level
> 1) and the child news objects (level 2).
>
> I used to call nfgnav from dtml like this:
>
> <dtml-var "nfgnav.TreeMenu(PARENTS,REQUEST,initlevel=2,Meta_Types='News',sort='navsort')">
>
> So I want to call nfgnav a level higher then the ZPT.

from the top of my head:
<dtml-var
"nfgnav.TreeMenu(PARENTS[:-1],REQUEST,initlevel=2,Meta_Types='News',sort='navsort')">
--
-------------------------------------------------------------
Who's got only a hammer sees the world as a nail
hans augustin  (software developer)           hans@beehive.de
beehive elektronische medien GmbH       http://www.beehive.de
phone: +49 30 847-82 0                  fax: +49 30 847-82 299