|
I would put your html inside your perl script like this:
print <<"HTML";
<html>
<head>
<body>
</body>
</html>
HTML
Remember that this is very picky...there should be no space between the << and the "HTML", and the HTML marker should be unquoted and at the beginning of an empty line; no other code is allowed on this line, including the end-of-file marker and semi-colon. If it is on the last line of your program, there must be a carriage return. (Be sure to include the content-type). What this does is interpolates the perl variables used as if the entire section was in double quotes. So you can have <td>$perlVariable</td>. You can use this over and over:
#perl script
print <<"HTML";
html stuff
HTML
#perl script
print <<"HTML";
html stuff
HTML
__________________
Some days you are the bug; some days you are the windshield.
|