[Zope] Rendering PageTemplateFile
Dieter Maurer
dieter@handshake.de
Tue, 24 Jun 2003 20:14:49 +0200
Jens Dobberthin wrote at 2003-6-24 12:39 +0200:
> is there any way to render a page template file that is located on the
> hard disk?
>
> Code excerpt in a product:
>
> def foo(self):
> pt = PageTemplateFile('show.zpt', _prefix=skins_prefix)
> print pt # prints <PageTemplateFile at 0x89c5000>
> return pt() # --> error
You page template is not acquisition wrapped (and therefore cannot
define "here", "container", ...
Try:
pt= PageTemplateFile(...).__of__(self)
Dieter