--- index.cgi 2009/04/18 14:05:13 20
+++ index.cgi 2009/04/18 14:08:52 21
@@ -9,6 +9,8 @@
use Data::Dump qw/dump/;
use Time::HiRes qw/time/;
+print qq{Content-type: text/html\r\n\r\n};
+
our $dsn = 'DBI:Pg:dbname=syslog';
our $user = 'dpavlin';
our $table = 'log';
@@ -63,7 +65,7 @@
my $sth = $dbh->prepare( $sql );
$sth->execute;
$t = time() - $t;
- print header, qq|$t
|, join(qq| | |, @cols), qq| |
|;
+ print qq|$t|, join(qq| | |, @cols), qq| |
|;
while ( my @row = $sth->fetchrow_array ) {
my $n = shift @row;
$n = 'NULL' unless defined $n;
@@ -74,7 +76,7 @@
exit;
}
-print header, q|
+print q|