Just to point out an alternative. I presume you want to use XML::Checker to validate the XML against a DTD and not just see if the XML itself is valid. If that's the case, XML::LibXML is a fine alternative. I use it in production code to validate XML against DTDs.
-- vek --my $parser = XML::LibXML->new; $parser->validation(1); eval { $doc = $parser->parse_string($xml); }; if ($@) { # XML not well formed, error handling here... } eval { $doc->validate; }; if ($@) { # XML did not pass DTD validation, error handling here... }
In reply to Re: XML::Checker
by vek
in thread XML::Checker
by aroso
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |