hi,
if anyone has the time or the patience, could someone please tell me
what's wrong with this script?
it's simple..it's supposed to open a file and print the contents (i'm
learning slowly but surely)...anyhow...i keep getting 500 errors and
the server log says that there's a premature end to the file but i
don't see how.
thanks!
#!/usr/bin/perl
use CGI::Carp qw(fatalsToBrowser);
require "subparseform.lib";
&Parse_Form;
$data_file="trouble.cgi";
open(DAT, $data_file) || die("Could not open file");
@raw_data=<DAT>;
close(DAT);
print "Content-type: text/html\n\n";
print "<HTML><BODY>";
foreach $site(@raw_data)
{
chop($site);
($reporter,$problem,$mrttech)=split(/\|/,$site);
print "$reporter $problem $mrttech ";
print "<BR> \n";
}
print "</BODY></HTML>";
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/