in reply to XML::Simple - multi level

There is a note on the module documentation that says:
Note 1: The default value for 'KeyAttr' is ['name', 'key', 'id']. If y +ou do not want folding on input or unfolding on output you must setti +ng this option to an empty list to disable the feature.
If your element 'name' had a different name, things would have worked as you expected, but by default XML::Simple recognizes 'name' hence the need to setup the module with an empty 'KeyAttr' as runrig said.

Replies are listed 'Best First'.
Re^2: XML::Simple - multi level
by djbryson (Beadle) on Dec 11, 2007 at 16:58 UTC
    Set keyattr to and empty list and it's working now. Thanks guys. However, I suppose I don't really need this module for what i'm doing, but I'm glad I got it working. I'm just extracting one tag from an XML file. I can do that just as easily with a slurp and a regex.