Groups | Blog | Home
all groups > flash data integration > october 2005 >

flash data integration : Text in XMLfiles is not correctly displayed


allMyNicksAreTaken
10/15/2005 6:25:25 AM
Hi,

I made a website entirely in Flash. During intialization, the flash-program
downloads an external xml-file containing all the text of he different sections
of the site. This way, content and UI are nicely seperated and a user can
switch easily between different languages.

All data is correctly loaded, but there's a problem with special characters
that are used in the XML. A few examples:
& is shown as &
?, ? are not displayed
vari?teit is displayed as variit (?te is not displayed)
ge?ntegreerd is displayed as geegreerd (?nt is not displayed)
cre?ren is displayed as creen (?re is not displayed)
...

How to solve this problems? A suppose this problem is caused by wrong
character encoding. I tried following character definitions at the start of
every XML:
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="iso-8859-1"?>

Thanks a lot for trying to solve this problem. It would help me a lot

greetz,

Pieter S.
tomeanand NO[at]SPAM hotmail.com
10/17/2005 6:46:02 AM
Hi

you can use CDATA tags to solve this problem
you need to restructure you xml file for this

<yourNode someName="xxxxx"><![CDATA[ All your text with special character
goes here]]></yourNode >

try to restructure the xml like this, use CDATA targs..

anand




caballitodetroya
11/3/2005 12:00:00 AM
hi
i have the same problem.
tried CDATA but it wouldn?t work.
without CDATA i get perfect text without bold but with accents!?
with CDATA i get "undefined"

Ps: i'm using the XML Connector to bind the textfield to the XML file.
Any clue?
all i want to do is set some of my words in bold!!!
kanniss
11/3/2005 8:21:31 PM
Hi,
I am also having a similar issue. I have a text component which pulls text
from an XML file. In this file, I have a few single quotes (e.g. ...Dean's
list), but the single quotes are not rendered in the actual SWF file at run
time. I tried using the CDATA tag as follows:

<detail><![CDATA[ Dean?s List 2003]]></detail>

but did not have any success.

Can anyone propose a solution?

Thanks in advance,

Daniel
adireddy
11/8/2005 10:01:38 AM
To display special characters like ?, ? etc you need to save the XML file in
UTF-8 encoding format.

To do that open the XML file in Notepad and choose File -> Save As and select
UTF-8 in the encoding option at the last.
AddThis Social Bookmark Button