XML::Simple, how to catch error: not well-formed?
by Kelvin Wu other posts by this author
Dec 28 2004 2:51AM messages near this date
view in the new Beta List Site
Re: XSLT question : excluding attributes
|
Re: XML::Simple, how to catch error: not well-formed?
& XSLT Hi list,
Is it possible to catch XML error when parsing XML files using XML::Smple?
my $xml = XMLin($file);
next if $xml-> error();
something like that.
I want to catch any error if the XML file is not a valid XML file,
rather than stop my script at :
not well-formed (invalid token) at line 1, column 269, byte 269 at
/usr/lib/perl5/site_perl/5.8.0/i586-linux-thread-multi/XML/Parser.pm
line 185
_______________________________________________
Perl-XML mailing list
Perl-XML@[...].com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Thread:
Kelvin Wu
Grant McLean
|