Hi friend
I am basically a web designer and don’t have much knowledge about action scripting and xml, my client require me to make a dynamic xml menu and vertical submenu.
I tried to look for tutorials on the web and found this script really easy, but got stuck in the programming part, please help figure where I am going wrong?
Flash code:
menuXml = new XML();
menuXml.ignoreWhite = true;
menuXml.onLoad = function(success) {
if (success) {
menuItem = this.firstChild.childNodes;
for (var i=0; i<menuItem.length; i++) {
item = _root.attachMovie("itemClip", "itemClip" + i, i);
item._x = 0;
item._y = 20*i;
item.itemLabel.text = menuItem*.attributes.name;
item.myUrl = menuItem*.attributes.url;
item.onRelease = function() {
getURL(this.myUrl,"_blank");
}
}
}
}
menuXml.load("myMenu.xml");
xml Code:
<?xml version="1.0"?>
<myMenu>
<myItem name="Philter" url="http://www.philterdesign.com/" />
<submenu name =="Philter" url="http://www.philterdesign.com </submenu>
<submenu name =="Philter" url="http://www.philterdesign.com </submenu>
<myItem name="Studiowhiz" url="http://www.studiowhiz.com/" />
</myMenu>
1.I am having problem with position the menu in the right place (_y axis).
2. And creating a vertical submenu with differentiating color of the button.
Please friend help , I am asking this question since 4 days. i would really appreciate if some one help me here. I will be really kind of you.
I have attached the file.