>In my case I have to declare the document as "iso-8859-1" and the image
>data encoded on base64 passes the XML parser without any error.

I just wanted to clear this up so that no one was left with the
impression that the use of base64 encoding was at all related
to your problem.  All characters resulting from base64 encoding
lie entirely within the 7-bit ASCII subset and had nothing to do
with the error you encountered by using an incorrect encoding
declaration.  As you mention yourself in the first message:

>But after passing the character data the parser answers with an illegal
>unicode character error (for example 0xFD)

The need to provide an iso-8859-1 encoding must be coming from
document data other than that in the base64 encoding.

Regards,
Glenn



                                                                                       
                              
                    "Thomas                                                            
                              
                    Heitzmann"             To:     [EMAIL PROTECTED]         
                              
                    <thomas.heitzman       cc:                                         
                              
                    [EMAIL PROTECTED]>             Subject:     Re: Again: unicode character 
error parsing an encoded base64 
                                            string  (Solution found)                   
                              
                    08/03/2001 05:50                                                   
                              
                    AM                                                                 
                              
                    Please respond                                                     
                              
                    to xerces-j-dev                                                    
                              
                                                                                       
                              
                                                                                       
                              



Hello folks,

I've found the solution by the following reply to a similiar question:

>An invalid XML character (Unicode: 0xfc) was found in the element content
of the document.
> Reply 2 of 2     < Previous | Next >  Back to Question | Return to Search

>  Author: Johannes Koch ([EMAIL PROTECTED])
>Date: Jul 16 2001 6:25AM
>Sources: comp.text.xml

>Volkmar Nissen schrieb:
>>
>> I got that message parsing a XML document with character
encoding='UTF-8'
>> (Using xalan 2.1, xerces 1.4)
>> the XML document  contains '#' characters. After removing this
characters
>> from the document, everything works fine.
>>
>> AFAIK, the '#' character is a allowed character in a XML document. So I
>> don't know, why  this message is generated.

>'#' is Unicode 0x23. 0xfc is ''. Perhaps the encoding for the character
>'' is not in utf-8 as you posted, but in iso-8859-1.
>--
>Johannes Koch  . IT Developer
>Pixelpark AG   . http://www.pixelpark.com
>Rotherstrae 8 . 10245 Berlin  .  Germany
>phone: +49 30 5058 - 1288  .  fax: - 1355


In my case I have to declare the document as "iso-8859-1" and the image
data encoded on base64 passes the XML parser without any error.


Thomas Heitzmann wrote:

> Hello folks,
>
> I tried to transfer image data via xml by encoding this data on the
> base64
> algorithm.
>
> This should be the usual way to handle binary data passing an
> XML-Parser,
> in my case this is the xerces SAX -Parser (version 1.4.2).
>
> For the first time, the image data passes completly the
> characters-method,
> so I can extract the image succesfully after base64 decoding.
>
> But after passing the character data the parser answers with an illegal
> unicode character error (for example 0xFD)
>
> I tried to declare the document data as UTF-8 with no success.
>
> Thanks for any help
>
> Thomas

--
----------------------- DO IT RIGHT. SHE ----------------------
SHE Informationstechnologie AG
Thomas Heitzmann                           Fon:+49 621 5200-188
Portal Computing                           Fax:+49 621 5200-550
Donnersbergweg 3                       [EMAIL PROTECTED]
D-67059 Ludwigshafen                         http://www.she.net
-------------------- Enterprise Solutions ----------------------



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to