[Zope-dev] local/set

Anthony Baxter Anthony Baxter <anthony@interlink.com.au>
Sat, 11 Dec 1999 13:19:28 +1100


>>> "Phillip J. Eby" wrote
> Let: allows read-only variables to be computed whose values are usable
> within a DTML nesting scope.
> 
> Local: allows writable variables to be computed, whose values are usable
> and changeable within a DTML nesting scope.
> 
> Set: singleton tag that changes the value of a "local" variable, as long as
> it was defined in the innermost surrounding "local" block.

Given the ongoing discussions over the difficulty of learning DTML, 
the general ugliness of DTML, and the discussion over what DTML is 
actually good for, isn't adding local/set just taking us further and
further down the path of horror? 

It's already _way_ too easy to start with a simple DTML page, and then
extend it and extend it beyond any sane limits until you end up with a
perl-like morass of code. Utterly unmaintainable. 

Surely using PythonMethods or ExternalMethods is a much much better 
approach here, rather than bolting yet another bag onto the side of 
DTML.

dtml-let solves a problem: it's a much nicer way to spell _.namespace()

I'm not convinced that _.namespace is such a great idea in the first
place.

I've seen too much DTML that makes me cry when I have to go and
maintain it - I'd actually like to see it made a bit more obvious
when you should stop doing things in DTML.

-- 
Anthony Baxter     <anthony@interlink.com.au>   
It's never too late to have a happy childhood.