in reply to Duplicate entries with nested xml

The documentation for XML::Simple says:

The use of this module in new code is discouraged. Other modules are available which provide more straightforward and consistent interfaces. In particular, XML::LibXML is highly recommended.

The major problems with this module are the large number of options and the arbitrary ways in which these options interact - often with unexpected results.

It might as well say:

Abandon all hope, ye who enter here.

If you want stable, reliable XML handling, XML::Simple is really not your friend.

Once the formatting of your question is fixed so I can actually see your XML, I may be able to offer some more specific advice.

Update: the formatting has been fixed, but there still seems to be errors in the listing for your XML. For example, the following is not a valid XML entity reference:

"\&envPageConfig";

And you show two contradictory listings for the file called envPageConfig.xml.