in reply to Perl DSC and or XML::Simple
my $refdata = XMLin('C:/myxmltest.xml'); foreach my $href ( @$refdata->{'Map'} ){ print $href->{'MapId'} ."\n"; }
Update: I should explain. You forgot the @. $refdata->{'Map'} is an array reference so you make it @$refdata->{'Map'} and you can act on all of the values that the array reference references.
2nd Update: I forgot the curly braces. Doh!
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Perl DSC and or XML::Simple
by Anonymous Monk on Sep 01, 2002 at 11:44 UTC |