[Zope] Newbie: Missing a Variable (TAL/METAL Question)

Dieter Maurer dieter at handshake.de
Fri Jul 28 16:31:15 EDT 2006


beno - wrote at 2006-7-28 08:01 -0700:
>Right. My bad. However, that didn't work either :( The error was it couldn't find 'var'.

I used "var" to indicate some variable. It was not meant that you
use "var" literally...

>So I tried 'item'. It couldn't find 'item'. So I tried this code:
>   
>      <td tal:define="number repeat/item/number"
>            tal:content="number">1</td>
>
>  and it complained that it couldn't find 'number'.

You must be very careful: both in reading and in writing.
And you must try to understand how things work.
And you must provide full error information (i.e. "Error Type",
"Error Value" and the traceback -- you find all of them
in the "error_log" object in your Zope "Root Folder").

If you use "repeat/variable" (again, "variable" is not meant literally,
but *some* "variable"), then "variable" must be a repeat variable
defined by an enclosing 'tal:repeat="variable ..."'.
If this is the case, then "repeat/variable/number" should work.



-- 
Dieter


More information about the Zope mailing list