in reply to Mid-row colspans with CGI.pm
Well, I almost had it right the first time:
#!/usr/bin/perl -w use strict; use CGI::Pretty ":standard"; my $q= CGI->new(); print $q->table( { -border=>1, -cellpadding=>2, -cellspacing=>2 }, Tr( { -align=>'LEFT', -valign=>'CENTER' }, [ $q->td( [ 'one', 1, 'I' ] ), $q->td(['one', '1', 'I']), $q->td(['two']) . $q->td({-colspan=>'2'}, ['2']), $q->td({-colspan=>'2'}, ['three', 'III']), $q->td({-colspank=>'3'}, ['four']), ] ) );
Thanks to jcwren for including fully functional code so I could test what I wrote.
- tye (but my friends call me "Tye")
|
|---|