I'm in the process of learning Zope hacking, and I'm having a really
hard time getting a page counter to work. It isn't even that page
counters are all that important to me, it's that I feel that if I can't
even do something this simple, what hope do I have doing something
really hard?

Here's what I've done.
(1) Under "Properties" I've created two properties (both ints)
        counter_starting_value, which I've set to 11 (arbitrarily)
        counter_value, which I've set to 0

(2) I then created a DTML method. I spent some time pouring through the
DTML Reference, but I really didn't find a lot on how to modify
variables. Here's what I tried:
<dtml-if counter_value>
        <dtml-let counter_value = counter_value + 1>
        <dtml-let counter_value = counter_starting_value>
<dtml-var counter_value>

This didn't work. The error message reported that the syntax in the
first (and probably the second, but I never got past the first) dtml-let
command was wrong.

I also tried things like
<dtml-var "counter_value=counter_value+1"> # got a syntax value for
dtml-var here
<dtml-var expr="counter_value=counter_value+1"> #same problem here.

Is there an easy way to do this?

Thanks in advance,


Richard P. Muller, Ph.D. 

Zope maillist  -  [EMAIL PROTECTED]
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-dev )

Reply via email to