15 Aug
2001
15 Aug
'01
8:15 p.m.
smoerk@gmx.de wrote:
is it possible to use ZPT without Zope in Python program?
It is possible to use PageTemplates without Zope, not ZPT (short for Zope Page Templates). With ExtensionClass, TAL, ZTUtils, and PageTemplates on your Python path, you should be able to:
from PageTemplates.PageTemplate import PageTemplate pt = PageTemplate() pt.write('''<p tal:define="x options/x" ... tal:content="python:x+1">???</p>''') print pt(x=1) <p>11</p>
Cheers, Evan @ 4-am & Zope