--On 1. Februar 2006 09:04:36 +0100 Frank Burkhardt <[EMAIL PROTECTED]> wrote:

Hi,

in Zope2 there's a test() method that can be used in TAL (*). Is there
something comparable in Zope3?

I know how to write such a method but how to make it available in the
namespace of TALES-"python:"-expressions? I would like to write
expressions like this:

<div tal:attributes="class python: 'foo' + test(condition == True,'
bar','')" />


You can write this in Python as

   condition and true_expression or false_expression

-aj

Attachment: pgpV4jynQWzQQ.pgp
Description: PGP signature

_______________________________________________
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users

Reply via email to