Flash XML function OnLoad reports wrong document lenght

Dear all,

I am building an application using flash that reads XML documents that contain information such as date/course/file-type/file-text about a set of documents. The content of these text documents could be in spanish, english, french, etc., in the xml document, the content is copied in a <![CDATA[ ]] tag.

The function onLoad behaves incorrectly when the text contained in the <![CDATA[ ]> tag has spanish characters such as accented vowels, or – or “ …
onLoad stops reading the xml file and reports a wrong document length. This function stops counting the xml document nodes when it encounters text that has any of the characters mentioned above.

The following encoding is used:
<?xml version=“1.0” encoding=“ISO-8859-1” ?>

An example of one node of an xml document that causes the onLoad function to stop counting is copied here:

  • <text>
  • <![CDATA[
    AutoevaluaciónAprendí muchísimo en esta clases de español. Primero, me gusta que la clase fue muy íntima porque no había demasiados estudiantes en la clase. También, los estudiantes que asisten la clase estuvieron confiados a aprender la lengua y convertirse en hablantes fluidos. Además, usted estaba muy dedicada a ayudándonos a alcanzar estas metas. He visto una mejora en casi toda parte de mi sistema de habilidad español. Puedo escribir ensayos largos de varios tipos y temas. Puedo hacer proyectos de investigación totalmente en español. Aprendí como dar presentaciones largas en español enfrente de una clase. También, empecé a escribir más poesía en español este cuatrimestre. Yo había esperado que mis destrezas orales habría mejoradas más. Es obvio que yo necesito practicar más. En el futuro, espero que yo continuo a mover más cerca y más cerca de mis metas. Mil gracias para una clase fenomenal.
    ]]>
    </text>

Can someone explain what is wrong with the text? I have read that using the encoding=“ISO-8859-1” extends the character set to include spanish, french and other languages.

Thanks all for your help,
mari