--- test/html-webhacc/cc.cgi 2007/07/01 06:21:46 1.7 +++ test/html-webhacc/cc.cgi 2007/07/01 10:02:24 1.8 @@ -23,6 +23,11 @@ ## TODO: _charset_ + if ($http->meta_variable ('PATH_INFO') ne '/') { + print STDOUT "Status: 404 Not Found\nContent-Type: text/plain; charset=us-ascii\n\n400"; + exit; + } + my $input_format = $http->parameter ('i') || 'text/html'; my $inner_html_element = $http->parameter ('e'); my $input_uri = 'thismessage:/'; @@ -97,6 +102,9 @@ $opt{line} = $opt{line} - 1 || 1; print STDOUT qq[
Line $opt{line}
\n]; } + $opt{type} =~ tr/ /-/; + $opt{type} =~ s/\|/%7C/g; + $msg .= qq[ [Description]]; print STDOUT qq[
$msg
\n]; }; @@ -190,6 +198,10 @@ my $onerror = sub { my %opt = @_; my ($cls, $msg) = get_text ($opt{type}, $opt{level}); + $opt{type} = $opt{level} . ':' . $opt{type} if defined $opt{level}; + $opt{type} =~ tr/ /-/; + $opt{type} =~ s/\|/%7C/g; + $msg .= qq[ [Description]]; print STDOUT qq[
] . get_node_link ($opt{node}) . qq[
\n
], $msg, "
\n"; }; @@ -455,4 +467,4 @@ =cut -## $Date: 2007/07/01 06:21:46 $ +## $Date: 2007/07/01 10:02:24 $