We don't bite newbies here... much | |
PerlMonks |
Re: XML log filesby mirod (Canon) |
on Dec 05, 2002 at 16:13 UTC ( [id://217797]=note: print w/replies, xml ) | Need Help?? |
Entities to the rescue! You can just create a wrapper that will include just the root element and a call to an entity referencing the log file, which itself has no root tag: log.xml is:
log.data is:
XML processors should have no problem with this (tested with perl -MXML::Simple -MData::Denter -e'print Denter XMLin( "log.xml");'). You just output your log data to log.data and use log.xml when you want to do XML processing on it.
In Section
Seekers of Perl Wisdom
|
|