On Wed, 28 Dec 2005 12:26:13 -0330
Rocky Burt <[EMAIL PROTECTED]> wrote:
> Its my personal opinion that anytime a page template
> requires logic complicated enough to warrant using a
> 'python:' expression, that logic should be re-thought and
> placed into a view class.  I know that some python:
> expressions are fairly simple, but for an HTML designer,
> *any* python: portions are dangerous to touch (and
> shouldn't be touched by the HTML designer).
> What do you all think?


I think it's a terrible idea. Why do I have to learn a new
programming syntax just to get things done in ZPT? I do
*most* expressions in Python syntax, with very few

The python syntax is explicit, clear, and matches the syntax
used elsewhere in the program.

Besides, there are plenty of places where it is convenient
to use simple mathematical relationships to manage
presentation, such as:

<span tal:condition="python: i % 5 = 3">

for something that should occur in "every 5 repeats" of

There's no way that sort of things should be considered
"business logic" -- it's just pagination or color bars or
some such thing.

Terry Hancock ([EMAIL PROTECTED])
Anansi Spaceworks http://www.AnansiSpaceworks.com

Zope3-dev mailing list
Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com

Reply via email to