Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: XML::Simple: list all element attributes

by frozenwithjoy (Priest)
on Apr 08, 2015 at 06:03 UTC ( [id://1122772]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    use Data::Printer;
    p $data;
    
  2. or download this
    \ {
        node   [
    ...
            }
        ]
    }
    
  3. or download this
    foreach my $node (@{$data->{node}}) {
        print $node->{name}.": ".$node->{text}."\n";
    }
    
  4. or download this
    1st node: Text of 1st node
    2nd node: Text of 2nd node
    3rd node: Text of 3rd node
    
  5. or download this
    my $xml = XML::Simple->new( KeyAttr => 1, ForceArray => 0, KeepRoot =>
    + 1 );
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (5)
As of 2024-04-24 03:54 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found