I wrote:

> I'm using DocumentTemplate from Python (not in Zope) and I want to
> use a custom format 'javascript_quote' that I've written.

Kapil Thangavelu wrote:

> you should implement a formating function and register it with
> special_format.
> for examples of both look near the end /DocumentTemplate/DT_Var.py

Thanks. I did as below, which worked. Is that the official way? - I
couldn't see any dedicated function to register a format.

    DT_Var.special_formats['javascript_quote'] = javascript_quote

Hamish Lawson

Do You Yahoo!?
Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
or your free @yahoo.ie address at http://mail.yahoo.ie

Zope maillist  -  [EMAIL PROTECTED]
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-dev )

Reply via email to