On Thu, Nov 19, 2009 at 9:03 AM, Andrey Fedorov <
anfe...@gmail.com> wrote:
> Yup, the latest one works great. Thanks!
> There isn't any way to access the outer @, is there? For example, in
> tornado's templates, I'd do -
> <table>
> {% for i, n in enumerate(cells) %}
> <tr>
> {% for j, colr in enumerate(n) %}
> <td class="cell" id="cell_{{i}}_by_{{j}}"
> style="background: {{colr}};"></td>
> {% end %}
> </tr>
> {% end %}
> </table>
> - Andrey
I think you're asking for @index there. @index will give you the
inner one. I don't think it's implemented but if you need it,
name.@index should give you an outer index.
It might have to be something like cells.@.@index, which is pretty
ugly. But generally to get a table, using an array of objects is more
conventional than a 2D array, which will avoid this ugliness.
Andy