View previous topic :: View next topic |
Author |
Message |
astolitu
Joined: 26 Jun 2004 Posts: 547 Location: Zagreb
|
Posted: 17.08.2006 19:49 Post subject: xml help |
|
|
AS:
Quote: |
var nNews:XML = new XML;
nNews.ignoreWhite = true;
nNews.load("thTarget.xml");
nNews.onLoad = function (loaded){
if(loaded){
th1.loadMovie(this.firstChild.childNodes[0].childNodes[0].childNodes[0].attributes.thMali);
tOut1.sOut.htmlText = this.firstChild[0].childNodes[0].childNodes[0].firstChild.nodeValue;
trace("jeaaaa");
}
else{
trace("nije se lodalo");
}
}
|
xml:
Quote: |
<?xml version = "1.0" encoding = "UTF-8"?>
<news>
<lista>
<th>
<thumb thMali = "pictures/test1.jpg"><![CDATA[]]></thumb>
<out><![CDATA[Sold Out]]></out>
</th>
</lista>
</news>
|
problem je sta mi flash vraca text = undefined
kako ovo rijesit? |
_________________ http://www.markobjedov.com/ |
|
Back to top |
|
|
Peewee
Joined: 12 Jan 2004 Posts: 711 Location: Velika Gorica
|
Posted: 17.08.2006 21:47 Post subject: |
|
|
meni se isto desavalo sa galerijom... i onda sam skuzio da mi ustvari on jos nije loado taj xml, a ja od njega trazim da mi da neke informacije iz njega i onda sam odvojio loadanje xml i rad sa informacijama... tako radi aj mejlat cu ti to, pa prouci... |
_________________ Pi (Pee) is a mathematical constant equal to approximately 3.14.
zivili!!! |
|
Back to top |
|
|
astolitu
Joined: 26 Jun 2004 Posts: 547 Location: Zagreb
|
Posted: 18.08.2006 02:25 Post subject: |
|
|
Peewe nije u tome problem krivo sam napisa jer sam brzoplet i glup
umjesto ovog:
tOut1.sOut.htmlText = this.firstChild[0].childNodes[0].childNodes[0].firstChild.nodeValue;
treba ovo:
tOut1.sOut.htmlText = this.firstChild.childNodes[0].childNodes[0].childNodes[1].firstChild.nodeValue; |
_________________ http://www.markobjedov.com/ |
|
Back to top |
|
|
|