Alternatively instead of doing this:
You could do this instead:print $query->start_table({-align=>'center'}), $query->start_Tr({bgcolor=>'#9933FF'}), $query->start_th({-align=>'center', -colspan=>5}), $query->stron +g('VOLUNTEER'), $query->start_th({-align=>'center', -colspan=>5}), $query->stron +g('DATE'), $query->start_th({-align=>'center', -colspan=>5}), $query->stron +g('UNDO'), $query->end_Tr; $query->start_Tr({bgcolor=>'#99FF99'}), $query->start_td({-align=>'center', -colspan=>5}), $query->stron +g($name), $query->start_td({-align=>'center', -colspan=>5}), $query->stron +g($signup_date), $query->start_td({-align=>'center', -colspan=>5}), $query->chec +kbox(-name=>"remove",-value=>$signup_date), $query->end_Tr; print $query->end_table;
This does exactly the same thing and it's a lot easier to read (and debug!) as well. You also don't have to worry about the closing tags 'cause CGI.pm will take care of them for you.#!/usr/bin/perl use CGI qw(:standard); print table({-align=>'center'}, Tr({bgcolor=>'#9933FF'}, th({-align=>'center', -colspan=>5}, [strong('VOLUNTEER'), strong('DATE'), strong('UNDO')] ) ), Tr({bgcolor=>'#99FF99'}, td({-align=>'center', -colspan=>5}, [strong($name), strong($signup_date), checkbox(-name=>"remove",-value=>$signup_date)] ) ) );
Gary Blackburn
Trained Killer
In reply to Re: Why won't my form print to screen
by Trimbach
in thread Why won't my form print to screen
by mnlight
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |