[Zope] Superfast PageTemplates: Call for expertise
Thomas Guettler
Thomas Guettler <thomas@thomas-guettler.de>
Tue, 18 Feb 2003 18:50:37 +0100
On Mon, Feb 17, 2003 at 10:57:27PM +0000, Peter Bengtsson wrote:
> I just ran my python product for a spin with the ZopeProfiler (well done
> Dieter Maurer!).
> My product uses PageTemplates (mostly through PageTemplateFile) and the
> PageTemplate stuff really goes at the top of the CPU timing.
> I.e. the PageTemplate rendering is "slow". DTML is probably not faster and
> I'm not "blaming" PageTemplates as such because I understand that they have
> a lot of work to do.
>
I use the following code to produce HTML in my small python product
OOPServer:
def(self, ....):
"docstring"
ret=[]
ret.append(self.standard_html_header())
ret.append('''
<form action="...">
%s %s ...
</form>''' % (self.var1, self.var2))
ret.append(self.standard_html_footer())
return string.join(ret)
thomas
--
Thomas Guettler <guettli@thomas-guettler.de>
http://www.thomas-guettler.de