#!/usr/bin/perl use XML::Simple; use Data::Dumper; my $xml = qq|<?xml version="1.0" standalone="no"?> <!DOCTYPE document SYSTEM "whocares.dtd"> <document> <QuestionList> <Question> <Id>3</Id> <Text>Are dingos your friend?</Text> <Answer>Satisfactory</Answer> </Question> </QuestionList> <QuestionList> <Question> <Id>11</Id> <Text>Should this run out of memory?</Text> <Answer>No</Answer> </Question> </QuestionList> </document>|; my $xml_ref = XMLin($xml); print $xml_ref->{'QuestionList'}->{'Question'}->[0]->{'Answer'};
In reply to XML Parsing Out of Memory error by JackHammer
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |