Hi!
I'm using the Soap Stuff to call webservices and this uses the XMLDOMParser to parse the response. This works well normally. But as soon as there is a carriage return (
) somewhere in the response, the result returned by call invoke contained an error message: SAXParseException: XML expected. The parser doesn't seem to able to handle carriage returns although 
 is XML 1.0 compliant. What is wrong? Where would I have to change this?
Thanks! Daria
Daria Spescha wrote:
Hi!
I'm using the Soap Stuff to call webservices and this uses the XMLDOMParser to parse the response. This works well normally. But as soon as there is a carriage return (
) somewhere in the response, the result returned by call invoke contained an error message: SAXParseException: XML expected. The parser doesn't seem to able to handle carriage returns although 
 is XML 1.0 compliant. What is wrong? Where would I have to change this?
Thanks! Daria
Not sure...maybe XMLTokenizer>>initEntities. I override it in SeasideTesting to add nbsp.
David
I have looked at the problem and I have figured out that the parser is able to handle entities given as numbers (&#..; constructs), but it can handle hexadecimals only if the character numbers (A-F) are written in uppercase letters. To solve the problem, it is enough to add the following line at the end of XMLTokenizer class>>initialize and doit in the method. ($a to: $f) do: [:each | DigitTable at: each asciiValue put: each asUppercase digitValue].
Not sure...maybe XMLTokenizer>>initEntities. I override it in SeasideTesting to add nbsp.
I tried to do this for the german umlaute (ä ... ). If I give a character like $< as the value for the entity declaration, it works fine. But if I give "normal" characters like $ä or $h, then they are doubled. From Mäuse I get Määuse. I stepped through the parsing with the debugger but I couldn't find out where the duplication takes place.
Daria
-----Ursprüngliche Nachricht----- Von: squeak-dev-bounces@lists.squeakfoundation.org [mailto:squeak-dev-bounces@lists.squeakfoundation.org] Im Auftrag von C. David Shaffer Gesendet: Donnerstag, 24. Februar 2005 14:57 An: The general-purpose Squeak developers list Betreff: Re: XML Parser
Daria Spescha wrote:
Hi!
I'm using the Soap Stuff to call webservices and this uses the XMLDOMParser to parse the response. This works well normally. But as soon as there is a carriage return (
) somewhere in the
response,
the result returned by call invoke contained an error message: SAXParseException: XML expected. The parser doesn't seem to able to handle carriage returns although 
 is XML 1.0 compliant. What is wrong? Where would I have to change this?
Thanks! Daria
Not sure...maybe XMLTokenizer>>initEntities. I override it in SeasideTesting to add nbsp.
David
-- C. David Shaffer http://www.cs.westminster.edu/~shaffer http://www.shaffer-consulting.com
Hi,
could please enter these bugs (and your workarounds as notes) on mantis (http://bugs.impara.de) so they don't get lost?
Thanks
Michael
Daria Spescha wrote:
I have looked at the problem and I have figured out that the parser is able to handle entities given as numbers (&#..; constructs), but it can handle hexadecimals only if the character numbers (A-F) are written in uppercase letters. To solve the problem, it is enough to add the following line at the end of XMLTokenizer class>>initialize and doit in the method. ($a to: $f) do: [:each | DigitTable at: each asciiValue put: each asUppercase digitValue].
Not sure...maybe XMLTokenizer>>initEntities. I override it in SeasideTesting to add nbsp.
I tried to do this for the german umlaute (ä ... ). If I give a character like $< as the value for the entity declaration, it works fine. But if I give "normal" characters like $ä or $h, then they are doubled. From Mäuse I get Määuse. I stepped through the parsing with the debugger but I couldn't find out where the duplication takes place.
Daria
-----Ursprüngliche Nachricht----- Von: squeak-dev-bounces@lists.squeakfoundation.org [mailto:squeak-dev-bounces@lists.squeakfoundation.org] Im Auftrag von C. David Shaffer Gesendet: Donnerstag, 24. Februar 2005 14:57 An: The general-purpose Squeak developers list Betreff: Re: XML Parser
Daria Spescha wrote:
Hi!
I'm using the Soap Stuff to call webservices and this uses the XMLDOMParser to parse the response. This works well normally. But as soon as there is a carriage return (
) somewhere in the
response,
the result returned by call invoke contained an error message: SAXParseException: XML expected. The parser doesn't seem to able to handle carriage returns although 
 is XML 1.0 compliant. What is wrong? Where would I have to change this?
Thanks! Daria
Not sure...maybe XMLTokenizer>>initEntities. I override it in SeasideTesting to add nbsp.
David
-- C. David Shaffer http://www.cs.westminster.edu/~shaffer http://www.shaffer-consulting.com
could you please post a test so that the XML parser gets improved?
Stef
On 24 févr. 05, at 14:54, Daria Spescha wrote:
Hi! I'm using the Soap Stuff to call webservices and this uses the XMLDOMParser to parse the response. This works well normally. But as soon as there is a carriage return (
) somewhere in the response, the result returned by call invoke contained an error message: SAXParseException: XML expected. The parser doesn't seem to able to handle carriage returns although 
 is XML 1.0 compliant. What is wrong? Where would I have to change this? Thanks! Daria
squeak-dev@lists.squeakfoundation.org