Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling

Re: XML::Parser sigh...

by GrandFather (Saint)
on Jul 27, 2005 at 21:19 UTC ( #478726=note: print w/replies, xml ) Need Help??

in reply to XML::Parser sigh...

Can you provide a small sample of your input data that demonstrates the problem, an example of the result you are getting and the result you expect?

Perl is Huffman encoded by design.

Replies are listed 'Best First'.
Re^2: XML::Parser sigh...
by rogue90 (Novice) on Jul 27, 2005 at 21:35 UTC
    I see a couple of options here, one of which I don't know if its possible. Easy would be to create a new file with the ampersands parsed out. Thats pretty clunky though. I am hoping I can replace them on the fly before the parser sees them. I am new to XML::Parser though and I am not sure if its possible.
Re^2: XML::Parser sigh...
by rogue90 (Novice) on Jul 27, 2005 at 21:29 UTC
    The error for the ampersand is
    not well-formed (invalid token) at line...
Re^2: XML::Parser sigh...
by rogue90 (Novice) on Jul 27, 2005 at 21:27 UTC
    <data> <RECORD> <id>1381</id> <title>Water & Fluids</title> <year>1986</year> </RECORD> ... </data>

      The parsers that I've looked at require the whole XML documents. Internally they may swallow a bite at a time, but you've got to give them the whole thing as either a string or a file handle.

      I guess options are either preprocess the whole document or use a tied variable passed to the parser to process the file as the parser reads it.

      Perl is Huffman encoded by design.

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://478726]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (2)
As of 2023-03-29 16:33 GMT
Find Nodes?
    Voting Booth?
    Which type of climate do you prefer to live in?

    Results (72 votes). Check out past polls.