[Zope] ZPT - getting at an object's parent

Max M maxm@mxm.dk
Fri, 15 Mar 2002 07:45:18 +0000


Joel Burton wrote:

>On Thu, 14 Mar 2002, Tom Nixon wrote:
>
>>How do I get at the attributes of an object's parent?
>>
>to get property "spam" of the parent of object "foo":
>
>foo.aq_parent.spam
>

Is it not good tone anymore to use:

foo.PARENTS[1].spam  ???

regards Max M