[ZPT] object located in in DTML but not ZPT

Dieter Maurer dieter at handshake.de
Fri Dec 19 17:50:21 EST 2003


Jeremy Ryan wrote at 2003-12-15 22:44 -0000:
> ...
>    <input type="hidden" name="pk" tal:define="primaryKey
>here/sequencePuller" tal:attributes="value string:$primaryKey" />
>
>This seems like an awful hack to me, and I'd like to do it in entirely in
>TAL/TALES. I want to do something like:
>
>      <input type="hidden" name="pk" tal:attributes="value
>pkGenerator.getNextValue()" />
>
>but that doesn't work.

You want to learn about the "python" TALES expression type
(--> Zope Book).

Short: '...tal:attributes="value python: pkGenerator.getNextValue()"...'
will work.

-- 
Dieter



More information about the ZPT mailing list