[ZDP] BackTalk to Document The Zope Book (2.5 Edition)/Advanced Page Templates

webmaster@zope.org webmaster@zope.org
Thu, 26 Sep 2002 16:28:52 -0400

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


      It's not always easy to figure out the best way to customize look
      and feel in different parts of your site. In general you should
      use slots to override presentation elements, and you should use
      Scripts to provide content dynamically. In the case of the links
      example, it's arguable whether links are content or
      presentation. Scripts probably provide a more flexible solution,
      especially if your site includes link content objects.

        % Anonymous User - Apr. 29, 2002 6:29 pm:
         Is this the syntax you were suggesting - with the same 'use-macro' and 'href' corrections as above? 
         <span metal:use-macro='container/master.html/macros/sidebar">
            <span metal:fill-slot="links"
                  tal:repeat="link here/getLinks">
                  <a href="link url"
                     tal:attributes="href link/url"
                     tal:content="link/name">link name</a>

        % Anonymous User - Sep. 26, 2002 4:28 pm:
         i still have trouble with <a href="link url">
         a href attribute value with a space inside? 
         maybe a typo, intended <a href="link_url">
         ok, it is overwritten by tal:attributes anyway, but i lost a minute thinking...