Error when using XML::Simple with XML::LibXML

L

Leif Wessman

I've successfully installed XML::Simple and XML::LibXML.

the following code gives me an error:
----
#!/usr/local/bin/perl

....

use XML::Simple;
$XML::Simple::pREFERRED_PARSER = 'XML::LibXML';
my $xs1 = XML::Simple->new();
my $doc = $xs1->XMLin($input, forcearray=>1);
----

The error is:

Can't locate object method "xml_decl" via package "XML::Simple" at
/home/leif/perl/lib/perl5/site_perl/5.8.0/i386-linux/XML/LibXML.pm
line 369.
at /home/leif/perl/lib/perl5/site_perl/5.8.0/XML/Simple.pm line 295

What have I done wrong?

Leif
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,968
Messages
2,570,153
Members
46,701
Latest member
XavierQ83

Latest Threads

Top