Ciao a tutti.
Con queste righe qui, riesco a leggere il primo nodo del file. Come faccio a leggere il nodo 4 ad esempio?
codice:mio_xml = new XML(); mio_xml.path = this; mio_xml.ignoreWhite = true; mio_xml.onLoad = function(success) { if(success){ var t1 = "<font color='#006699'>"; var t2 = "</font>"; var prezzo = this.firstChild.attributes.prezzo; var testo = this.firstChild.attributes.testo; var img = this.firstChild.attributes.img; this.path.testo += t1 + testo + t2 + " "; this.path.testo += "Prezzo: " + t1 + prezzo + t2 + " "; loadMovie(img, _root.mc); } else { this.path.testo = "caricamento errato"; } }; mio_xml.load("file.xml");

Rispondi quotando