[Zope] dtml-var enhancement suggestion

James W. Howe jwh@allencreek.com
Mon, 31 Jan 2000 13:46:42 -0500


I've noticed that in some of my DTML code I often times do something like this:

<dtml-if foo>
     <dtml-var foo>
<dtml-else>
     Some default text
</dtml-if>

I do this so that I can build a template and view it without getting key 
errors.  It would seem that a simple extension to dtml-var could make this 
code a lot cleaner.  Would it be terribly unreasonable to add a 
"default=xxx" parameter to dtml-var?  My code above could then be rewritten:

<dtml-var foo default="Some default text">

Comments welcome.

James W. Howe				mailto:jwh@allencreek.com
Allen Creek Software, Inc.		pgpkey: http://ic.net/~jwh/pgpkey.html		
Ann Arbor, MI  48103