[Zope] Access to DTML Document properties

Luciano Ramalho luciano@magnet.com.br
Wed, 10 Mar 1999 01:45:22 -0300


At 22:31 09/03/99 -0500, Pavlos Christoforou wrote:
>You can use the PARENTS variable.
>
>so if you have a folder which contains two DTML Documents A and B then
>you can access B's properties from A by:
><!--# var "PARENTS[0].B.name"-->
>PARENTS[1] will return the folder or containing object one level up and 
>PARENTS[-1] will return the top most Folder.

Thanks for your help, Pavlos. I found another way. Instead of writing:

<!--#var expr="_['sub-document'].author"-->

I wrote this, and it worked fine:

<!--#var expr="_.getitem('sub-document').author"-->

I found a way, but I don't understand why the first syntax worked fine with
Folders and fails with DTML Documents. If anyone would like to clarify the
semantic difference between _['sub-document'] and
_.getitem('sub-document'), I would be even happier.

By the way, Pavlo's site http://www.gaaros.com:9673/ is useful!

[]s
Luciano