[Zope] How to find out whether index_html was acquired?

Dieter Maurer dieter@handshake.de
Thu, 16 Aug 2001 20:49:54 +0200 (CEST)


Hamish Lawson writes:
 > I'm wondering whether there is a way to determine whether the 
 > index_html method was found in the current folder or was acquired 
 > from a folder above.
This means, you ask the current folder whether is has an "index_html".
You can do this with the followin Python script "hasItem":

    argments:	id

    try: context[id]; return 1
    except KeyError: return 0


Dieter