XML, the Perl Way

Processing XML with Perl Michel Rodriguez

XML::Simple

Example: loading a configuration file

Introduction to XML::Simple

Description

XML::Simple - Trivial API for reading and writing XML (esp config files)

XML::Simple loads an XML file in memory, in a convenient structure, that can be accessed and updated, then output back.

A number of options allow users to specify how the structure should be built. It can also be cached.

Notes: You should read the documentation for the forcearray option. Also note that name, key and id attributes have a special role in XML::Simple (see the keyattr option).

Why use XML::Simple?

Why NOT use XML::Simple?



XML::Simple

Example: loading a configuration file