im using a rss feed that has images, bt the images are not wraped in <image> instead there in the description tag in html format. Is there a way i can pull that image out of the rss so i can use it in a mc?
this is the code im playing with.
var loader:URLLoader = new URLLoader();//creates new loader instance
loader.addEventListener (Event.COMPLETE, onLoaded);//listens for loaded content
lb.addEventListener (Event.CHANGE, itemChange);// change listbox item on event
//lb change fucntion
function itemChange (e:Event):void {
ta.text = lb.selectedItem.data;
}
var xml:XML;
function onLoaded (e:Event):void {
//grabs xml data and puts into xmllist
xml = new XML(e.target.data);
var il:XMLList = xml.channel.item;
var it:XMLList = xml.channel.item.title.text();
var id:XMLList = xml.channel.item.description.text();
var iLink:XMLList = xml.channel.link;
var iData:XMLList = xml.channel.data;
/*for (i=0; i<10; i++){*/
trace ("ttem: "+il[1]);
trace ("title: "+it[1]);
trace ("description: "+id[1]);
trace ("link: "+iLink[1]);
/*}*/
for (var i:uint=0; i<il.length(); i++) {
lb.addItem ({data:il.description.text()*,
label:il.title.text()*});
}
}
//loops through data and adds it to the list
loader.load (new URLRequest("http://blog.holidays.net/index.php/category/St.-Patrick's-Day/feed/"));
any one have any ideas?