Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

A very annoying character (�) in CDATA

Status
Not open for further replies.

orielkin

Programmer
Aug 14, 2002
5
IL
Hi you,
I thought XML parser allows anything in CDATA, nevertheless, while inserting the character � the parser alerts that the file is not well-formed, even though it's in the CDATA scope. PLEASE HELP!!!
By the way, I'm using UTF-8 encoding in my xml, trying to change it didn't help.
 
Well you don't say what parser your using and you don't post the error message it't giving. So i can tell you only that MSXML has no probelms parsing the following xml file
Code:
<?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?>
<ROOT>
  <Test><![CDATA[ Hello world?]]></Test>
</ROOT>
good luck
-pete
 
Sorry, I'm using XMLSpy and MSXML2, both generating error message - ]] expected - the file is not well-formed. at the location of the special charater
 
I used XMLSpy 3.5, MSXML3 and fairly current (last 3 months) version of the Java Xerces parser.

All parsers emit no errors when parsing the file i posted. Did you try the file i posted with your parsers?

-pete
 
Hi Palbano,
Appreciate your help.
I have tried your file and there's no problem with it, nonetheless, It doesn't have the special character I'm talking about( The big square, &#65533)
thanx, Ori
 
Ori,

I have no idea what has happened. You first post is now displaying the “BOX” character. When I first read your post that character was displaying a ‘?’ character NOT THE BOX! That’s why my file has the ‘?’ character in it!!!

So have you solved your problem? If not can you place that xml file on a web server renamed to a .txt file so we can access it? The reason to do that is it may be difficult to obtain the special character through the forum mechanism.

-pete
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top