>>>>> "James" == James L <[EMAIL PROTECTED]> writes:

James> hi,
James> i am trying to do breakon on tables, i.e omit the cell
James> content if it is a repeat.

James> i have a variable breakon which is a interger that
James> used to check if first number of columns per row is a
James> repeat. however, the follow code gives unexpected
James> token error on
James> "<td>&nbsp;</td>";  
 
James> what is the valid syntax here?

James> [% FOREACH row IN rows %]
James>     [%  cur_fields = row.first( breakon ).join('');
James>         IF cur_fields == prev_fields;
James>           FOREACH field in row;
James>             IF loop.count < breakon

Missing a semicolon here ==>

James>               "<td>&nbsp;</td>";
James>             ELSE;
James>               "<td>$field &nbsp;</td>";
James>             END;
James>           END;
James>         ELSE;
James>           FOREACH field in row;
James>             "<td>$field &nbsp;</td>";
James>           END;
James>         END;
James>         prev_fields = cur_fields
James>     %]
James> [% END %]

James> thanks!

James> James.

-- 
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<[EMAIL PROTECTED]> <URL:http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!

_______________________________________________
templates mailing list
[email protected]
http://lists.template-toolkit.org/mailman/listinfo/templates

Reply via email to