Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

XML::LibXML

by ForgotPasswordAgain (Deacon)
on Jul 11, 2008 at 14:13 UTC ( #696968=note: print w/ replies, xml ) Need Help??


in reply to Seralize a XML tree from XML::Parser

XML::LibXML can serialize XML:

    use XML::LibXML;
    my $parser = XML::LibXML->new();

    my $doc = eval { $parser->parse_file($file) };
    if ($@) {
        print STDERR "Couldn't parse '$file', skipping\n";
    } else {
        my $dom = $doc->documentElement;

        # use DOM methods here

        $doc->toFile($file);
    }


Comment on XML::LibXML

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://696968]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (9)
As of 2014-12-25 13:00 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (160 votes), past polls