RE: [Zope] testing with dtml-if
<dtml-if my_variable> do stuff </dtml-if> I think... -----Original Message----- From: garry saddington [mailto:garry@joydiv.fsnet.co.uk] Sent: Thursday, September 04, 2003 1:25 PM To: zope@zope.org Subject: [Zope] testing with dtml-if Does anyone know the syntax to use with dtml-if when i want to do something like this: <dtml-if <dtml-var w>==1> do stuff </dtml-if> ? thanks garry _______________________________________________ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev ) The information contained in this email message may be privileged and is confidential information intended only for the use of the recipient or any employee or agent responsible for delivering it to the intended recipient. Any unauthorized use, distribution or copying of this information is strictly prohibited and may be unlawful. If you have received this communication in error, please notify the sender immediately and destroy the original message and all attachments from your electronic files.
On Thu, 2003-09-04 at 16:19, Meilicke, Scott wrote:
<dtml-if my_variable> do stuff </dtml-if>
I think...
The above will test the *truth* of my_variable. That overlaps with testing that it is equal to 1, but isn't quite the same. What you really want is: <dtml-if "my_variable==1"> do stuff </dtml-if> HTH, Dylan
participants (2)
-
Dylan Reinhardt -
Meilicke, Scott