in reply to Re^2: Parsing with XML::Simple
in thread Parsing with XML::Simple

Okay. I ran this code and noticed that you probably want to start at the top.

my $result = $data->{'soap:Envelope'}{'soap:Body'}{'soap:Fault'}{detail}{MaxCode}; # removed unnecessary punctuation

This won't give you the answer you seek but push you in the right direction. I'll also give you a hint... You told it to treat MaxCode as an array.

Replies are listed 'Best First'.
Re^4: Parsing with XML::Simple
by Anonymous Monk on Aug 23, 2016 at 19:55 UTC
    Got to work by simplifying the code like this, with one issue:
    ... my $parser = new XML::Simple; my $data = $parser->XMLin($content); my $result = $data->{'soap:Body'}{'soap:Fault'}{'detail'}{'MaxCode'}; print $result->{content};

    The only thing is that once the value of "$result" is empty, I am getting this:
    Use of uninitialized value in string