Cascading Menu driven by XML

Okay I have the menu that hga77 built but I want to add a few attributes to it. Everytime I add the attributes I get more buttons for somereason or another and the function does not work like it should. Hga77’s script is easy to follow but difficult to moddify.

I want to add something like the following to his menu so I can set everything up in the XML file.

vt.menuObj[“item”+j].what = menu_xml.firstChild.childNode*.attributes.what;
vt.menuObj[“item”+j].where = menu_xml.firstChild.childNodes{i].attributes.where;
vt.menuObj[“item”+j].the_type = menu_xml.firstChild.childNodes*.attributes.type;

and then be able to have either the main buttons or the sub buttons do the following function:

onRelease = function() {
if (this.the_type != undefined) {
if ((this.the_type == “geturl”) or (this.the_type == “getURL”)) {
unloadMovie(_root.dropZone);
getURL(this.what, this.where);
}
if ((this.the_type == “gotoAndPlay”) or (this.the_type == “gotoandplay”)) {
unloadMovie(_root.dropZone);
tellTarget (this.where) {
gotoAndPlay(this.what);
}
}
if ((this.the_type == “gotoAndStop”) or (this.the_type == “gotoandstop”)) {
unloadMovie(_root.dropZone);
tellTarget (this.where) {
gotoAndStop(this.what);
}
}
if ((this.the_type == “loadMovie”) or (this.the_type == “loadmovie”)) {
loadMovie(this.what, this.where);
}
if ((this.the_type == “attachMovie”) or (this.the_type == “attachmovie”)) {
tellTarget (this.where) {
attachMovie(this.what, this.what+i, i);
}
}
if ((this.the_type == “fsCommand”) or (this.the_type == “fscommand”)) {
unloadMovie(_root.dropZone);
fscommand(this.what, this.where);
}
if ((this.the_type == “function”) or (this.the_type == “Function”)) {
unloadMovie(_root.dropZone);
eval(this.where)this.what;
}
}
};

anyone?