XML parsing for thumbnails

I’m trying to modifiy a script I found on Hotscripts.com for my personal portfolio. The original creates navigation buttons for the projects and loads thumbnail buttons from an external XML file. I want to take it a step further by adding another step to the process. instead of loading just the project names as buttons I want to create a “catagorie” then the the appropriate “projects”. I got the catagorie and project navigation to load but when you click the project the proper thumbnails don’t load.

the function to load the thumbnails from the project navigation looks like this:

function projectListLoad(whichproject){
//loops through to clear the thumbnails
for (var rr = 0; rr<noofrow*noofcolumn; rr++) {
rr = rr+pageindex;
this.thumbHolder_mc[“thumbframe”+rr].removeMovieClip();
this.thumbHolder_mc[“thumbframein_mc”+rr].removeMovieClip();
rr = rr-pageindex;
}
/////////////////////////////////////////////////////////////////
//parameters set in the XML document for thumbnails functionality
param = this.portfolioList_xml.firstChild.firstChild;
pc = int(param.attributes.noofcolumn);
pr = int(param.attributes.noofrow);
ptx = int(param.attributes.thumbxs);
pty = int(param.attributes.thumbys);
_global.ptw = int(param.attributes.thumbwidth);
_global.ptl = int(param.attributes.thumbheight);
/////////////////////////////////////////////////////////////////
//counts the # of catagories in the XML
//sets varibles to read the format and info back to into flash
var projectCountXML = this.portfolioList_xml.firstChild.childNodes.child Nodes;
projectCount = this.portfolioList_xml.firstChild.childNodes[whichcatagorie].childNodes.length;
var projectNode = this.portfolioList_xml.firstChild.childNodes[whichcatagorie].childNodes[p].firstChild;//IMAGE TAG
var projectBoxData = createResourceList(projectNode.childNodes, pc, pr, ptx, pty, ptw, ptl);//Actual Images

trace ("PROJECT COUNT = " + projectCount);
trace ("PROJECT NODE = " + projectNode);

//catagorie NAMES GET TRANSFORMED INTO NAVIGATION///////////////////////////////////////////////////////////////////////////////
for (p=0; p<projectCount; p++) {
this.projectDisplay_mc.attachMovie(“projectNames_m c”, “projectNames_mc”+p, 100+p);
this.projectDisplay_mc[“projectNames_mc”+p].projectnametxt.text = this.portfolioList_xml.firstChild.childNodes[whichproject].childNodes[p].attributes.projectname;
this.projectDisplay_mc[“projectNames_mc”+p]._x = 5;
this.projectDisplay_mc[“projectNames_mc”+p]._y = p14;
this.projectDisplay_mc[“projectNames_mc”+p].sett = p;
this.projectDisplay_mc[“projectNames_mc”+p].onRelease = function() {
currentpage = 1;
for (var rr = 0; rr<noofrow
noofcolumn; rr++) {
rr = rr+pageindex;
this.thumbHolder_mc[“thumbframe”+rr].removeMovieClip();
this.thumbHolder_mc[“thumbframein_mc”+rr].removeMovieClip();
rr = rr-pageindex;
}
projectListLoad(this.sett);
_global.whichProject = this.sett;
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
};
}
}

I hope someone can help me with this.
If you need the source files or any other information let me know.
Thanks