[Zope] Re: ZPT Problem

Maik Jablonski maik.jablonski@uni-bielefeld.de
Sun, 05 Jan 2003 10:38:55 +0100


beno wrote:
> Hi;
> I want my titles to render automatically. But even the default code in 
> the 2.6 distro for *standard_template.pt* doesn't work:
> 
> <html metal:define-macro="page">
>   <head>
>    <metal:block define-slot="head">
>    <title tal:content="template/title">The Title</title>
>    </metal:block>
>   </head>
>   <body>
>     <div metal:define-slot="body">
>     This is where the page's body text goes.
>     </div>
>   </body>
> </html>
> 
> This renders an empty string for *title*. Why?

Hi,

  <title tal:content="template/title">The Title</title>

renders the title of the template. You want the title of the current 
"context":

  <title tal:content="here/title">The Title</title>
                     ~~~~

\mj