[Zope] Changing list elements (was: [Zope] 2d list manipulation)

Dieter Maurer dieter@handshake.de
Sun, 10 Sep 2000 09:24:25 +0200 (CEST)

Tim Russell writes:
 > .... 2 dimensional list access and modification of elements ....
 > I can easily access the value of
 > an element using:
 >    <dtml-var "col[index1][index2]">
 > However, the difficulty comes when trying to change the value of one of
 > these elements....

There is no easy and safe way to do it in DTML (because a list
does not have a method to replace a list element. If interested
in a hack, you may look at the list methods "remove" and "insert").
The easiest thing is to write an external (or Python) method.