What would you do with HTML::Tidy? Something like this:
use HTML::Tidy;
my $tidy = new HTML::Tidy;
$tidy->ignore( type => TIDY_WARNING );
$tidy->parse( "foo.html", $contents_of_foo );
for my $message ( $tidy->messages ) {
print $message->as_string;
}
or some other level of automated HTML checking. With Test::HTML::Tidy (which I hope to get out tonight), you'll be able to do
html_tidy_ok( $html, "HTML is properly tidy" );
in your *.t scripts. Whee!
W3C Validator (Score:1)
http://validator.w3.org/ [w3.org]
Re:W3C Validator (Score:1)
Hrmm, i don't think so.
Check the source page [w3.org]. No mention of Tidy. Also, it says "OpenSP is the SGML and XML parser used by the service". So i assume it parses the output from that.
Re:W3C Validator (Score:1)
Re:W3C Validator (Score:2)
I'm not sure quite what tidylib does, but I'm going to give it a play and see what it does. If it's faster than onsgmls, then I'm all for it!
Your other option for validation is to get libxml2 (in its perl form XML::LibXML) set up. The disadvantage (which it shares with OpenSP) is that it requires you to have all the catalogs for html/xhtml set up correctly. I'm assuming that tidylib has all that sort of st
Re:W3C Validator (Score:2)
--
xoa