[ZPT] ZPT release 1.3 is up
Brent M Hendricks
brent@valinor.waldenweb.com
Mon, 21 May 2001 23:58:29 -0500
On Mon, May 21, 2001 at 03:01:10PM -0400, Evan Simpson wrote:
> Based on this, 'user' and 'attrs' are in, path modifiers are gone, and we
> have no way to spell "nocall" except for Python attribute access such as
> "python:x.get" and "python:path('a/b').method". For the moment, "exists:"
> is still in, since it's the easiest way to implement "python:exists('a/b')".
>
> Thanks to all who participated!
>
> There is now a PageTemplateFile class, and it is used to implement the Page
> Template add and edit pages. Python expressions can use path expressions
> (and other expression types) through builtin functions named after each
> type, as in "python:path('x/y | a/b') + 1".
Excellent! ZPT seems to be shaping up rapidly. I must confess I'm a
little disappointed by the absence of cond(). Did it get discarded
somewhere along the way or just not make it in yet? I'd really like
to be able to do something like:
<p tal:content="python:cond(foo(), 'Replacement text', default)" >
Some default text
</p>
--Brent
-------------------------------------------------------------------------
"The programmer, like the poet, works only slightly removed from pure
thought-stuff. He builds his castles in the air, from air, creating
by exertion of the imagination. Few media of creation are so
flexible, so easy to polish and rework, so readily capable of
realizing grand conceptual structures."
-- Frederick Brooks, Jr., The Mythical Man Month