newbie: Zope
Andrew Kuchling
akuchlin at mems-exchange.org
Thu Aug 31 18:13:34 EDT 2000
m.faassen at vet.uu.nl (Martijn Faassen) writes:
> Ah, so you found out, huh? :) DTML is horrible compared to Python.
> There are some guidelines to keep it simple. And move to Python
> as soon as you feel your DTML becomes too horrible.
I wonder if Neil Schemenauer's rewrite of PTL would be worth looking
at for use in Zope; it looks like this:
template barebones_header(title=None,
keywords=None,
description=None,
meta_info=None,
tree_info=None):
"""
<html>
<head>
<title>%s</title>
""" % html_quote(str(title))
if description:
'<meta name="description" content="%s">' % html_quote(description)
if keywords:
'<meta name="keywords" content=" html_quote(keywords) ">'
if meta_info:
meta_info
If you think this syntax looks like Python, don't worry, you're not
crazy. This code forms part of Quixote.
--amk
More information about the Python-list
mailing list