[Zope] How do you increment a variable?

Tony McDonald tony.mcdonald@ncl.ac.uk
Thu, 29 Jul 1999 15:11:17 +0100


I am having a *bad* day, I don't seem to be able to get *any* of my 
Zope stuff to work today :(

I can't get this to work.
<dtml-let counter="1">
Counter:<dtml-var counter>,
<dtml-var counter="counter+1">  (Line A)
<dtml-var counter>
</dtml-let>

I've tried the following variants on Line A.
1) <dtml-var counter="counter+1">
gives: Invalid attribute name, "counter", for tag <dtml-var 
counter="counter+1">

2) <dtml-var "counter=counter+1">
gives: Invalid Syntax <dtml-var "counter=counter+1">,

3) <dtml-call "counter=counter+1">
gives: Python syntax error <dtml-call "counter=counter+1">

I think all my Zope knowledge has gone out the window. It's Zope 
2.0b1 on Solaris 5.6

Tone (miserable)
------
Dr Tony McDonald,  FMCC, Networked Learning Environments Project 
http://nle.ncl.ac.uk/
The Medical School, Newcastle University Tel: +44 191 222 5888
Fingerprint: 3450 876D FA41 B926 D3DD  F8C3 F2D0 C3B9 8B38 18A2