[Zope] An oldnewbie writes (Was [Zope] DTML?)

Paul Browning paul.browning@bristol.ac.uk
Wed, 12 Jul 2000 09:23:12 +0100 (GMT Daylight Time)


> Date: Mon, 10 Jul 2000 17:49:25 -0400
> From: Shane Hathaway <shane@digicool.com>
> Organization: Digital Creations, Inc.
> To: Chris Withers <chrisw@nipltd.com>
> CC: zope@zope.org
> Subject: Re: [Zope] DTML?
> 
> Chris Withers wrote:

[snip]

> 
> > I also think having Python Methods ship with Zope would really help...
> 
> I'm working on enhancing Python Methods right now.  I'm close to
> getting them properly interfaced with DTML namespaces, so that DTML can
> invoke Python Methods using simpler DTML syntax.

I've followed this thread with particular interest. I'm almost
18 months old with Zope and have done many useful things with it.
But my journey up the learning cliff has been punctuated by
spells of doing other things (I'm not a programmer in real life)
during which I inevitably forget most of what I've just learned
about DTML (and slip back down the cliff).

OK, this is true of most things (computer languages, foreign
languages, mental arithmetic, parenthood, etc) - if you don't
use it, you lose it. But there is something about DTML that
distinguishes it (for me) from other languages - it's the rate
at which it decays on you. Python's decay constant is much
more favourable.

So I've learned a rule of thumb - if I'm writing DTML and
it isn't flowing then I really ought to be using Python. PythonMethods
are nice but, as they stand, you only have access to built-in
functions. So if you want to import modules you have to resort
to External Methods. [Am I talking nonsense here? My empirical
experience is that I can use string functions in a PythonMethod
but not, say, stuff from the time module. Neither string nor time
are built-in though ..... so why one and not the other?]

The point of these reflections:

* PythonMethods ought to be a high priority IMHO.

* DTML is holding Zope back for the rest of us (and is
  arguably a "proprietary" component of Zope (in that
  you can't use it anywhere else) - this is a disincentive
  to many power-Perl,JSP,<name-your-scripting-poison> users
  I suspect.

* Please can we import Python modules from PythonMethods (or
  can we already and I don't about it, or does this break the
  sandbox that PythonMethods is meant to provide)?

* Don't worry about changing DTML syntax. It's an excellent
  marketing ploy to ensure good sales of the 2nd edition of
  The Zope Book ;-)

Apologies for any misconceptions in any or all of the above.

Paul

--
 The Library, Tyndall Avenue, Univ. of Bristol, Bristol, BS8 1TJ, UK
     E-mail: paul.browning@bris.ac.uk  URL: http://www.bris.ac.uk/