[BiO BB] dumb question...

Anand Kumar anand.kumar at ifomis.uni-leipzig.de
Sun May 16 13:41:55 EDT 2004


Dan,

The problem is that the line 14075 is being sent to the XML parser module's handler. You could try to create a character handler before you call the parser.
Once you have declared lets say $trial,
you can then make a loop
if $trial is equal to <?xml version="1.0"?>
then read the current line and call the parser.
This way your hanlder will be active BEFORE the XML parser's handler is activated and the XML parser's handler will be activated everything your handler encounters the first line of the XML file.

Hope it helps.

Kind Regards,
Anand.

Am So 16.05.2004 19:38, Dan Bolser <dmb at mrc-dunn.cam.ac.uk> schrieb:

> 
> Using the XML::Parser perl module, how can I deal with multiple XML
> documents concatenated into a single file?
> 
> I get the following message after the first document...
> 
> junk after document element at line 14075, column 0, byte 674176 at
> /usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi/XML/Parser.pm
> line 185
> 
> Where line 14075 is the start of the next XML document...
> 
> 14075:<?xml version="1.0"?>
> 
> 
> Cheers,
> Dan.
> 
> _______________________________________________
> BiO_Bulletin_Board maillist  -  BiO_Bulletin_Board at bioinformatics.org
> https://bioinformatics.org/mailman/listinfo/bio_bulletin_board
> 

Anand Kumar MBBS, PhD
IFOMIS
Faculty of Medicine
University of Leipzig
Härtelstraße 16-18
04107 Leipzig
Germany
http://www.uni-leipzig.de/~akumar/








More information about the BBB mailing list