[ZDP] BackTalk to Document The Zope Book (2.5 Edition)/Appendix C: Zope Page Templates Reference

webmaster@zope.org webmaster@zope.org
Tue, 08 Oct 2002 23:00:48 -0400


A comment to the paragraph below was recently added via http://www.zope.org/Documentation/Books/ZopeBook/current/AppendixC.stx#3-84

---------------

      You can access the contents of the repeat variable using path
      expressions or Python expressions.  In path expressions, you write
      a three-part path consisting of the name 'repeat', the statement
      variable's name, and the name of the information you want, for
      example, 'repeat/item/start'.  In Python expressions, you use
      normal dictionary notation to get the repeat variable, then
      attribute access to get the information, for example,
      "python:repeat['item'].start".

        % SmileyChris - Oct. 8, 2002 11:00 pm:
         Some of these variables are methods so when called in a python expression you should call them like
         "python:repeat['item'].even()"
         Of the above variables, the following ones need to be called: (because they are methods)
         number, even, odd, first [e.g. "python:repeat['item'].first('fieldname')"], last [e.g.
         "python:repeat['item'].last('fieldname')"], length, letter, Letter, roman, Roman