Hi All,
I’ve got the following code, that works fine with just one button, but I can’t find the way to fix it to work with three buttons:
XML:
<links>
<link>http://www.dynamicdrive.com</link>
<link>http://www.google.com</link>
<link>http://www.apple.com</link>
</links>
AS:
var xml:XML = new XML()
xml.ignoreWhite = true;
xml.onLoad = function() {
loadLinks();
}
function loadLinks() {
var link:String = xml.firstChild.childNodes[0].childNodes[0]
btn_1.onRelease = function() {
getURL(link);
}
}
xml.load(“links.xml”);
Do you know how to fix this to make it work with “btn_2” and “btn_3” instances?
Thanks for your help!