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

webmaster@zope.org webmaster@zope.org
Mon, 18 Nov 2002 04:54:41 -0500


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

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

      The reasoning behind this ordering goes like this: You often want
      to set up variables for use in other statements, so 'define' comes
      first.  The very next thing to do is decide whether this element
      will be included at all, so 'condition' is next; since the
      condition may depend on variables you just set, it comes after
      'define'.  It is valuable be able to replace various parts of an
      element with different values on each iteration of a repeat, so
      'repeat' is next.  It makes no sense to replace attributes and
      then throw them away, so 'attributes' is last.  The remaining
      statements clash, because they each replace or edit the statement
      element.

        % Anonymous User - May 10, 2002 4:03 pm:
         Please replace from start of sentence to colon with following
         (reason to do this; as it stands, it says what was done, without why
         it was done, which is equally as important.) --

         The reasoning behind these precedences begins with the fact that TAL
         statements are being writtten as XML attributes.  By definition, XML
         attributes are un-ordered, and XML tools may, and do, rewrite attributes
         in any order they wish.  But, for TAL to be useful as a tmplating language,
         there has to be a predictable order of operations.  This order was
         chosen by the following rationale:

        % Anonymous User - Nov. 18, 2002 4:54 am:
         wasszup??