Changing space did not fix it. The workaround I found is this:
$for row in stuff.content:
<tr>
$for i in range(len(row)):
<td>$row[i]</td>
</tr>
</table>
ofcourse it meant I have to add range and len to templates:
web.template.Template.globals['len'] = len
web.template.Template.globals['range'] = range
Strange enough, If I print the type of row (i.e. $type(row) ), it prints
list.
Thanks for your help anyway
Behrang
----- Original Message -----
From: "Anand Chitipothu" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Wednesday, November 12, 2008 11:08 PM
Subject: [webpy] Re: displaying list of lists in template
>
>> $for row in stuff.content:
>> <tr>
>> $for cell in row:
>> <td > $cell </td>
>> </tr>
>>
>> </table>
>>
>> and I see:
>>
>> 3
>> 6
>> 9
>
> Looks like there is a space after '$for cell in row:'
>
> >
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"web.py" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/webpy?hl=en
-~----------~----~----~----~------~----~------~--~---