in reply to XML::Parser Tutorial
It's not very complicated, but I figured I'd post it as a reference.use IO::File; ... my $fileStream = new IO::File ("yourDocumentName.xml"); ... my $parser = new XML::Parser ( Handlers => { # Creates our parser object Start => \&hdl_start, End => \&hdl_end, Char => \&hdl_char, Default => \&hdl_def, } ); ... $parser->parse($fileStream);
I guess that would have been a lot easier in the first place. :-D$parser->parsefile($filename)
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Loading a Local File
by Anonymous Monk on Jan 04, 2018 at 11:09 UTC | |
by Corion (Patriarch) on Jan 04, 2018 at 12:07 UTC |