- From: Olivier Thereaux via cvs-syncmail <cvsmail@w3.org>
- Date: Thu, 12 Jun 2008 22:32:46 +0000
- To: www-validator-cvs@w3.org
Update of /sources/public/perl/modules/W3C/XHTML/HTMLCompatChecker/bin
In directory hutz:/tmp/cvs-serv24104/bin
Modified Files:
appCcheck.pl
Log Message:
special output of the CGI when no issue found
Index: appCcheck.pl
===================================================================
RCS file: /sources/public/perl/modules/W3C/XHTML/HTMLCompatChecker/bin/appCcheck.pl,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -d -r1.42 -r1.43
--- appCcheck.pl 12 Jun 2008 22:24:00 -0000 1.42
+++ appCcheck.pl 12 Jun 2008 22:32:44 -0000 1.43
@@ -74,6 +74,8 @@
<TMPL_UNLESS NAME="uri"><p>Enter the URI of an XHTML 1.0 document which you would like to check against the
<a href="http://www.w3.org/TR/xhtml1/#guidelines">HTML Compatibility Guidelines</a> .</p></TMPL_UNLESS>
+<TMPL_UNLESS NAME="has_messages"><p>No issue found in this document. Congratulations.</p></TMPL_UNLESS>
+
<TMPL_IF NAME="Abort">
<p>The document was not checked against HTML Compatibility Guidelines.
Reason: <em><TMPL_VAR NAME="Abort_Message"></em>.
@@ -194,12 +196,14 @@
$output->param(warning_count => 0);
$output->param(error_count => 0);
$output->param(Abort=>0);
+$output->param(has_messages=>0);
my $compat_parser = W3C::XHTML::HTMLCompatChecker->new();
if ($uri){
my @checker_messages = $compat_parser->check_uri($uri);
if (exists $checker_messages[0]) {
+ $output->param(has_messages=>1);
if ($checker_messages[0]{"severity"} eq "Abort"){
if ($checker_messages[0]{"message_text"} ne "Bad URI") { $output->param(uri => $uri);}
$output->param(Abort=>1);
@@ -224,7 +228,9 @@
$output->param(error_count => scalar @ERRORS);
}
- } else {$output->param(uri => $uri);}
+ } else {
+ $output->param(uri => $uri);
+ }
}
print $output->output();
Received on Thursday, 12 June 2008 22:33:21 UTC