7 td2html - Transform tabular data stream into a HTML table.
15 Takes a tabular data stream on STDIN and outputs a HTML table
16 enclosed in C<< <table>...</table> >> tags.
20 no if ($] >= 5.018), 'warnings' => 'experimental::smartmatch';
21 do '/usr/lib/tool/perl5/tabdata/common.pl' or die "$@";
26 $str =~ s/[><&\t]/'&' . {'>'=>'gt', '<'=>'lt', '&'=>'amp', "\t"=>'Tab'}->{$&} . ';'/eg;
31 print "<table border=\"1\">\n";
37 print join("</th><th>", map {html_escape
(unescape_tabdata
($_))} split $FS, $header);
46 print join("</td><td>", map {html_escape
(unescape_tabdata
($_))} split $FS, $row);