[Zope] DTML abc?

Dieter Maurer dieter@handshake.de
Sun, 10 Jun 2001 18:39:54 +0200 (CEST)


Oleg Broytmann writes:
 > On Sat, 9 Jun 2001, Arjan de Knegt wrote:
 > > I just have a tiny little DTML question that I can't seem to solve:
 > > Some of my object ID's contain dot's, e.g. "NicePicture.jpg". Yes, I do
 > > know  Zope doesn't need (or want?) the use of extension like "jpg" in
 > > object ID's , but I have my reasons to do so.  Now I simply would like
 > > to render this object with dtml-var. Al DTML syntaxes I can think of
 > > result in Zope errors, propably because Zope thinks the ".jpg" part is
 > > an object method instead of part of the object ID?
 > 
 >    <dtml-var "_['index.html']">
 >    <dtml-var "_.getitem('index.html', 0)">
 >    <dtml-var "_.getitem('index.html', 1)">
or just
      <dtml-var index.html>

Dots (or most other non-alphanumerics) are only problematic
in Python expression and can be used freely in DTML name arguments.


Dieter