Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

XML::LibXML

by ForgotPasswordAgain (Priest)
on Jul 11, 2008 at 14:13 UTC ( [id://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);
    }

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others contemplating the Monastery: (6)
As of 2024-03-29 12:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found