[ZPT] How can you use TAL to render a textarea property?

Trevor Toenjes zope at toenjes.com
Thu May 22 08:01:38 EDT 2003


> Trevor Toenjes wrote:
> > example:
> > <div tal:define="pss modules/Products.PythonScripts.standard">
> > <span tal:condition="python:here.content_html.editmode=='stx'"
> >       tal:replace="structure
> > python:pss.structured_text(here.content_html.page_copy)">page
> copy content
> > here rendered in STX</span>
> > </div>
> >
> > How can I do this with ZPT/TAL?
>
> Are you saying you want to have ZPT/TAL in the property of an
> object and have
> that executed using a code fragment similar to the above?

Yes.

Now I am just imagining this as a concept.
But since  STRUCTURE <tal:replace="structure..>  already exists to preserve
HTML,
it would be nice to have built in...

(My proposed modifiers)
tal:replace="structured_text    a la def structured_text(s) from API
tal:replace="page_template      **I just made this up.**

But how do I do it now?
thanks again.
-Trevor




More information about the ZPT mailing list