# XML Photogallery - one tiny problem

**URL:** <https://forum.kirupa.com/t/xml-photogallery-one-tiny-problem/216358>\
**Category:** flash\
**Created:** [February 15, 2007, 7:37pm UTC](https://forum.kirupa.com/t/xml-photogallery-one-tiny-problem/216358 "2007-02-15T19:37:22Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![grahamwok](https://avatars.discourse-cdn.com/v4/letter/g/3e96dc/32.png) [@grahamwok](https://forum.kirupa.com/u/grahamwok)\
**Post date:** [February 15, 2007, 7:37pm UTC](https://forum.kirupa.com/t/xml-photogallery-one-tiny-problem/216358/1 "2007-02-15T19:37:22Z")

</div>

Hi, I was wondering if someone out there could help me out with what might be a tiny problem… maybe.

I’d like my btn in flash to link to a URL. So i added it and then added to the actionscript the onrelease function for the button. I did a trace to see if it’s targetting the link in the xml, and it is but it won’t load the URL inside the xml. Please oh please… anyone?

**Here is my xml:**

\<?xml version=“1.0” encoding=“utf-8” standalone=“yes”?\>  
\<images\>  
\<pic\>  
\<image2\>[http://sumolab.co.uk/ymt\_yorkvenues/images/shire.jpg](http://sumolab.co.uk/ymt_yorkvenues/images/shire.jpg)\</image2\>  
\<link\>[http://www.grahamhowe.net](http://www.grahamhowe.net)\</link\>  
\</pic\>  
\</images\>

**The actionscript:**

delay = 3000;  
//-----------------------  
function loadXML(loaded) {  
if (loaded) {  
xmlNode = this.firstChild;  
image1 = [];  
total = xmlNode.childNodes.length;  
for (i=0; i\<total; i++) {  
image1\* = xmlNode.childNodes\*.childNodes[0].firstChild.nodeValue;  
link\* = xmlNode.firstChild.firstChild.childNodes[1].nodeValue;  
//trace (xmlNode.firstChild.childNodes[1].firstChild.nodeValue);  
[COLOR=Red]\*\*evening\_btn.onRelease = function(){  
getURL(link[0]);

```
        }**[/COLOR]

```

}

I’d be very grateful if anyone could send some advise my way.

Thanks in advance
