Title: Message
Thanks Derek. I've etherpeak to capture the raw packets coming across and using it's hex editor, have found that they appear to be hex FF FE.
 
I understand from searching and from old posts on this list that Xerces will have trouble that starts with this byte-order-mark. Is this still the case? If so, can anyone provide the known workaround for this?
 
Thanks again
Matt
-----Original Message-----
From: Derek [mailto:[EMAIL PROTECTED]
Sent: Friday, June 30, 2006 1:43 PM
To: axis-user@ws.apache.org
Subject: RE: Content is not allowed in prolog

Just a suggestion:
 
The message that you list below, with blanks between each character, looks to me like you might be trying to view Unicode text as if it were ASCII. Unicode uses sixteen bits to represent a character, while ASCII uses 8 (technically, 7), so each unicode character in the ASCII numeric range constitutes an all-zeroes byte plus a character byte. Perhaps the extra characters you are seeing in the message aren't really spaces, but are really null characters (0x00) and your editor or viewer translates them to spaces because it has no way to display nulls.
 
The two question marks before the initial "<?xml" prolog suggest to me that you are somehow getting junk characters (whitespace?) before your starting "<?xml" directive, which may cause the receiving system to get confused about what format the incoming text is in, since it uses the format of the first "<?xml" characters to make this determination, and assumes that the file starts with them. (Probably, it should simply reject any file that contains an "<?xml" that starts at any position other than character zero, but some XML parsers are more lenient than they should be). So the receiver may be incorrectly identifying the message as ASCII when it is actually Unicode, and translating the rest of the message accordingly.
 
Just a thought. That's the problem I've usually had when I see text files that look like this one.
 
Derek
-----Original Message-----
From: Matthew Brown [mailto:[EMAIL PROTECTED]
Sent: Friday, June 30, 2006 7:16 AM
To: axis-user@ws.apache.org
Subject: RE: Content is not allowed in prolog

Some followup information..
 
I've tested using .NET and their wsdl.exe tool to create a client to use the customer's web service. The response still looks the same, but .NET has zero issues parsing. Could this just be an XML parser issue? Can someone point me in the direction of how to change/configure the parser, or find out if parsing a message such as the one below (with all those extra spaces) is possible?
-----Original Message-----
From: Matthew Brown [mailto:[EMAIL PROTECTED]
Sent: Friday, June 30, 2006 9:23 AM
To: axis-user@ws.apache.org
Subject: RE: Content is not allowed in prolog

I happen to be having a similar error, although it isn't an endpoint issue.
 
The response we are getting back from the server looks like this:
 
??< ? x m l   v e r s i o n = " 1 . 0 "   e n c o d i n g = " u t f - 8 " ? > < s o a p : E n v e l o p e   x m l n s : s o a p = " h t t p : / / s c h e m a s . x m l s o a p . o r g / s o a p / e n v e l o p e / "   x m l n s : x s i = " h t t p : / / w w w . w 3 . o r g / 2 0 0 1 / X M L S c h e m a - i n s t a n c e "   x m l n s : x s d = " h t t p : / / w w w . w 3 . o r g / 2 0 0 1 / X M L S c h e m a " > < s o a p : H e a d e r > < R e s p o n s e H e a d e r   x m l n s = " h t t p : / / b l a h . c o m / C A S / " > < H e a d e r s > < / H e a d e r s > < / R e s p o n s e H e a d e r > < / s o a p : H e a d e r > < s o a p : B o d y > < G e t A c c o u n t I n f o r m a t i o n R e s p o n s e   x m l n s = " h t t p : / / b l a h . c o m / C A S / " > < A c c o u n t I n f o r m a t i o n R e s p o n s e   x m l n s : x s d = " h t t p : / / w w w . w 3 . o r g / 2 0 0 1 / X M L S c h e m a "   x m l n s : x s i = " h t t p : / / w w w . w 3 . o r g / 2 0 0 1 / X M L S c h e m a - i n s t a n c e "   x m l n s = " h t t p : / / b l a h . c o m / C A S / I V R . M e s s a g e D e f i n i t i o n s . x s d " >
 
     < N u m b e r O f M a t c h e s > 0 < / N u m b e r O f M a t c h e s >
 
     < M o n t h l y E x t e n s i o n A m o u n t > 0 < / M o n t h l y E x t e n s i o n A m o u n t >
    
     ....
 
with garbage characters inserted between each legit XML character (and two before the prolog).
 
Is it possible to add a handler to modify the raw response XML before Axis passes it off to the XML parser? Does anyone know? Is there some other simple setting I might be overlooking that might be causing this?
 
Thanks in advance.
 

Reply via email to