Darin Lee writes:
 > Here is the proverbial rub. If I want to *test* for the presence of
 > "navigation_name" so I can print "title_or_id" if it's not defined, Zope
 > simply skips the "navigation_name" property. It's like it always evaluates
 > to false!
 > <dtml-in "objectValues(['Category'])">
 >  <dtml-with sequence-item>
 >  <dtml-if "hasProperty('navigation_name')">
 >   <dtml-var navigation_name>
 > <dtml-else>
 >  <dtml-var title_or_id>
 > </dtml-if>
 > </dtml-with>
 > </dtml-in>
 > Doesn't work!
I do not yet know the method "hasProperty".

As a short term work around, you may try directly:

<dtml-if navigation_name>
  <dtml-var navigation_name>
  <dtml-var title_or_id>

This may acquire "navigation_name". Thus, you may restrict
namespace lookup with:

<dtml-with sequence-item only>
<-- code above-->


Zope maillist  -  [EMAIL PROTECTED]
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-dev )

Reply via email to