in reply to XML::Simple and newlines
Try the "noattr" option for XML::Simple.
#!/usr/local/bin/perl5.6.0 -w use strict; use XML::Simple; my $xs = XML::Simple->new(); my %data; $data{text} = q{ line 1 text line 2 text line 3 text }; print $xs->XMLout(\%data, noattr => 1)
The data will be preserved inside the tags, rather than as:!./t1.pl <opt> <text> line 1 text line 2 text line 3 text </text> </opt>
|
|---|