[ZPT] Help referencing variables

Jon Bowlas me at jonbowlas.com
Thu Feb 3 09:34:34 EST 2005


I’m trying to create a list that displays all the folders and the children
contained within each folder however I cannot seem to get the variable
‘albumname’ that I’ve defined in the script below to output in the TALES
expressions as outlined below, can anybody help?

<ul>
  <li tal:repeat="item here/objectValues"><div
tal:content="item/getId"></div>
  <div tal:define="albumname here/getId;
                           haskids here/$(albumname)/hasChildNodes"> 
    <ul tal:condition="haskids">
              <li tal:repeat="childitem here/$(albumname)/objectValues"><div
tal:content="childitem/getId"></div>
              </li>
   </ul>
   </div>
   </li>
</ul>

Hope someone can help as I don’t know what I’m doing wrong.

Regards

Jon




More information about the ZPT mailing list