[Zope] Test if an object exists in a folder

Dieter Maurer dieter@handshake.de
Thu, 1 Aug 2002 22:20:14 +0200


Max M writes:
 > ...
 > <dtml-if "aq_base.content_html()">
This will not work:

  "aq_base" is not available in TTW code.

  The code above would raise an exception, when "content_html" is
  not an attribute of "aq_base".

You come near (but it may fail in some circumstances) with

    <dtml-if "_.hasattr(aq_explicit,'content_html')">


Dieter