basic Perl/XML question

Walter Pienciak walter at frii.com
Fri Dec 3 10:06:13 CST 1999


Hi,

I'm starting to work more with the XML modules, but I have a pretty
basic question.  Most of the documents I see come in a jumbled form,
like

<tag><tag2>blah</tag2><tag3>blah<tag4>blah</tag/4></tag3></tag>

Yukk!  And when nothing is formatted for screen width, but runs on
for hundreds of characters . . . my poor eyes . . .

Is there a straightforward XML/Perl way to get indented formatting, like

<tag>
  <tag2>blah</tag2>
  <tag3>blah
    <tag4>blah</tag4>
  </tag3>
</tag>

There are 77 or so XML modules in CPAN now, so brute-force RTFM will
take a long time.

Walter




More information about the Boulder-pm mailing list