in reply to Re: HTATR II: HTML table generation via DWIM tree rewriting
in thread HTATR II: HTML table generation via DWIM tree rewriting

I suppose colours are best handled with CSS.

ESC[78;89;13p ESC[110;121;13p

  • Comment on Re: Re: HTATR II: HTML table generation via DWIM tree rewriting

Replies are listed 'Best First'.
3Re: HTATR II: HTML table generation via DWIM tree rewriting
by jeffa (Bishop) on Oct 30, 2003 at 18:31 UTC
    I agree:
    [% classes = ['odd','even'] %] [% BLOCK row %] [% class = classes.shift %] <tr> <td class="[% class %]">[% person.name %]</td> <td class="[% class %]">[% person.age %]</td> <td class="[% class %]">[% person.weight %]</td> </tr> [% classes.push(class) %] [% END %]
    But you, the programmer, still have to manage which class to use for which row.

    jeffa

    L-LL-L--L-LL-L--L-LL-L--
    -R--R-RR-R--R-RR-R--R-RR
    B--B--B--B--B--B--B--B--
    H---H---H---H---H---H---
    (the triplet paradiddle with high-hat)