Hi guys!
I’m new in this forum e above all I’m new in Flash, Actionscript and XML…
I have a “very” need of your help!!!
This is my problem: I realized a layout with flash cs4, actionscript 2.0. This layout load external SWFs. In this layout I created a movie clip called btnTesto which opens a popup and this popup load a file XML containing the text of the different SWFs.
The problem is that when I “navigate” the SWFs, the content of the popup is always the same…practically, it doesn’t read the whole XML…
This is the file XML:
*<?xml version=“1.0”?>
<audio>
<testo_wbt> *
<wbt1 testo = “Benvenuti nel corso Modello di Organizzazione e Gestione.” />
<wbt2 testo = “In tabella vengono presentate le caratteristiche del corso: titolo, durata, struttura e target al quale viene rivolto.” />
</testo_wbt>
</audio>
This is the code Actionscript I wrote (from a Kirupa document!!):
function loadXML(loaded) {
if (loaded) {
_root.audio = this.firstChild.firstChild.childNodes[0].firstChild.nodeValue;
testo_txt.text = _root.audio;
} else {
content = “file not loaded!”;
}
}
xmlData = new XML();
xmlData.ignoreWhite = true;
xmlData.onLoad = loadXML;
xmlData.load(“testo_audio.xml”);
Thank you very much for help!!!