[Zope] tal define and repeat

Mark Gibson mark@dimensional.com
Thu, 05 Dec 2002 12:12:05 -0700


David Bear wrote:
> I have want to use something like
> 
> <div tal:repeat="topic python:container.listZPT">
>   <p tal:content="topic/title_or_id"> stuff </p>
> </div>
> 
> the listZPT is a script the returns a list of page template objects.
> 
> this throws an TALES exception on repeat topic.
> 
> Is it not possible to repeat over a list object in TAL?


You need to 'call' your script:

i.e.:  <div tal:repeat="topic python:container.listZPT()">