XML hyperlinked images - array problem (optimising for F6)

This problem is really annoying me now. I’v e been stuck on it for a few days and having found a suitable solution online. Please help if you can.

I have a movieclip called ‘base’. This contains a ‘holder’ movieclip and two text boxes (Title_txt and Comments_txt). I’m populating these with XML data and would like to have the image (which is appearing in the holder movieclip) to link to the url when clicked. I’ve been tracing all variables which are coming through fine, however when using the onRelease function to link the url it’s only pulling through the last url in the array for all links.

Here’s my xml:

<?xml version=“1.0” encoding=“UTF-8”?>
<data>
<title name=“BIG”>
<comments>this is big</comments>
<image>thumbs/big.jpg</image>
<weblink>www.big.com</weblink>
</title>
<title name=“MEDIUM”>
<comments>this is medium</comments>
<image>thumbs/medium.jpg</image>
<weblink>www.medium.com</weblink>
</title>
<title name=“SMALL”>
<comments>small</comments>
<image>thumbs/small.jpg</image>
<weblink>www.small.com</weblink>
</title>
<title name=“TINY”>
<comments>tiny</comments>
<image>thumbs/tiny.jpg</image>
<weblink>www.google.com</weblink>
</title>
</data>

heres my AS (I’m tracing the onRelease rather than getURL in an attempt to de-bug :()

myXML = new XML()
myXML.ignoreWhite = true
myXML.load(“list.xml”)
myXML.ref = this
myText.html = true
myXML.onLoad = function(success){
if(success){
var root = this.firstChild
nodes = root.childNodes
for(var i=0; i<nodes.length; i++) {
attachMovie(“base”, “base”+i, i, {_x:(140i)+30, _y:5})
modelTitle = nodes
.attributes.name
subnodes = nodes*.childNodes;
modelStat = subnodes[0].firstChild.toString()
modelImage = subnodes[1].firstChild.toString()
modelLink = subnodes[2].firstChild.toString()
trace(modelLink);
this.ref[“base”+i].Title_txt.text = modelTitle;
this.ref[“base”+i].Comments_txt.text = modelStat;
this.ref[“base”+i].holder_mc.loadMovie(modelImage);
this.ref[“base”+i].hitArea = hotlink;
this.ref[“base”+i].onRelease = function() {
trace(modelLink);
}
}

} else trace(“Error loading XML document”)
}
stop();

Any help would be greatly appreciated…Thanks!