[Zope] ZPT newbie Q

G. Clifford Williams gcw-python@rezidew.net
Sun, 9 Mar 2003 23:46:43 -0600


Where does one find a list of all of the attributes and properties that can be 
called/referenced from TAL statements?

On Thursday 06 March 2003 08:22 pm, Chris Beaven wrote:
> <html>
>   <head>
> <title tal:content="template/title">Title</title>
>  </head>
>  <body tal:define="objects container/objectValues;temp
> python:objects.sort(lambda x, y: cmp(x.title.upper(), y.title.upper()))">
>    <font size=+1 tal:content="template/title">Title</font>
>   <ul tal:condition="objects">
>     <tal:block repeat="item objects">
>     <li tal:condition="python:item.id!=template.id">
>           <span tal:replace="item/title">ITEM</span>
>     </li>
>     </tal:block>
>   </ul>
>   </body>
> </html>
>
> You could also use item/title_or_id if you wanted to display the id if
> the object has no title...
>
> G. Clifford Williams wrote:
> >I'm just starting to work with ZPT (as of today), the first question I
> >have
> >is; Is there a way to keep "template/title" from being displayed in the
> >list
> >that is generated by the tal:repeate directive?
> >
> >I'd like to generate a list of links that does not include the
> >index_html
> >page.
> >
> >My second question is: Is there any way to sort the list that's
> >generated?
> >
> >--The code that I have--
> >
> > <title tal:content="template/title">Title</title>
> > </head>
> > <body>
> >   <font size=+1 tal:content="template/title">Title</font>
> >  <UL tal:condition="container/objectValues">
> >    <LI tal:repeat="item container/objectValues">
> >          <span tal:replace="item/title">ITEM</span>
> >    </LI>
> >  </UL>
> >
> >thanks in advance
> >
> >
> >_______________________________________________
> >Zope maillist  -  Zope@zope.org
> >http://mail.zope.org/mailman/listinfo/zope
> >**   No cross posts or HTML encoding!  **
> >(Related lists -
> > http://mail.zope.org/mailman/listinfo/zope-announce
> > http://mail.zope.org/mailman/listinfo/zope-dev )
>
> _______________________________________________
> Zope maillist  -  Zope@zope.org
> http://mail.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists -
>  http://mail.zope.org/mailman/listinfo/zope-announce
>  http://mail.zope.org/mailman/listinfo/zope-dev )