Action Script for parsing XML into flash.

4 replies [Last post]
Rocket
Rocket's picture
Offline
SX VIP
Joined: 2008/10/06

I am having huge trouble trying to figure this out.

This is what I have so far.

onSelfEvent (load) {
myXML = new XML;
myXML.ignoreWhite = true;
myXML.onLoad = DisplayData;
myXML.load("s0000444_e.xml");
}
function DisplayData (success) {
if (success) {
xmlOutput = this.body.childnodes.join('').split('').join('');
}
}

xlmOUtput = FAIL! Have any ideas on how to edit this action script to extract just the temperature and display it to the xmlOutput?

Xml files can be found here. http://dd.weatheroffice.gc.ca/citypage_weather/xml/MB/ "s0000444_e.xml"