# Question regarding tutorial 'Photo Gallery Using XML and Flash'

**URL:** https://forum.kirupa.com/t/question-regarding-tutorial-photo-gallery-using-xml-and-flash/264960
**Category:** flash
**Created:** [July 2, 2008, 3:25pm UTC](https://forum.kirupa.com/t/question-regarding-tutorial-photo-gallery-using-xml-and-flash/264960 "2008-07-02T15:25:08Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![jebrand](https://avatars.discourse-cdn.com/v4/letter/j/839c29/32.png) [@jebrand](https://forum.kirupa.com/u/jebrand)
#### Post date: [July 2, 2008, 3:25pm UTC](https://forum.kirupa.com/t/question-regarding-tutorial-photo-gallery-using-xml-and-flash/264960/1 "2008-07-02T15:25:08Z")

</div>

[http://www.kirupa.com/developer/mx2004/xml\_flash\_photogallery.htm](http://www.kirupa.com/developer/mx2004/xml_flash_photogallery.htm)

I found the above tutorial to be very useful and very easy to follow (which was a blessing for me as I am new to Flash and quite intimidated by it).

I would like to extend this tutorial to achieve another requirement but I am not sure if it is possible.

Please review the following concept and let me know if this is possible:  
In the tutorial the images and corresponding text is displayed dynamically based on an XML file. I would like to add a link ‘More Info’ movie clip to the interface which a user can click to get a page dedicated to that item. In other words, I would like a dynamic URL to be read from the XML and associated with the ‘More Info’ movie clip. I can get the URL read from the XML and stored into an array but I don’t know where or how to pass it so that the ‘More Info’ clip would contain it as a link.

Any assistance is appreciated

---

<div class="post-metadata">

### Author: ![randomagain](https://avatars.discourse-cdn.com/v4/letter/r/35a633/32.png) [@randomagain](https://forum.kirupa.com/u/randomagain)
#### Post date: [July 2, 2008, 3:43pm UTC](https://forum.kirupa.com/t/question-regarding-tutorial-photo-gallery-using-xml-and-flash/264960/2 "2008-07-02T15:43:39Z")

</div>

erm look at the code in the tut, the answer would be obvious,

---

<div class="post-metadata">

### Author: ![project107](https://avatars.discourse-cdn.com/v4/letter/p/eada6e/32.png) [@project107](https://forum.kirupa.com/u/project107)
#### Post date: [July 2, 2008, 4:36pm UTC](https://forum.kirupa.com/t/question-regarding-tutorial-photo-gallery-using-xml-and-flash/264960/3 "2008-07-02T16:36:56Z")

</div>

> [@randomagain;2352485](#):
>
> erm look at the code in the tut, the answer would be obvious,

I am starting to wonder why you even post - you obviously have no answer for this person.

jebrand,  
I would make a movieclip and give it the instance name of ‘info\_bttn.’ Then, in your actions layer with all the other actions, do something like this:

```auto

info_bttn.onRelease = function(){
      getURL(link*+", _blank");
}

```

This is assuming you are putting the url into an array named ‘link’. Cheers!

---

<div class="post-metadata">

### Author: ![natronp](https://avatars.discourse-cdn.com/v4/letter/n/87869e/32.png) [@natronp](https://forum.kirupa.com/u/natronp)
#### Post date: [July 3, 2008, 3:57pm UTC](https://forum.kirupa.com/t/question-regarding-tutorial-photo-gallery-using-xml-and-flash/264960/4 "2008-07-03T15:57:48Z")

</div>

I agree with Project107 about randomagain. Why post if you have nothing useful to say?

Jebrand, you need a simple function for your button that access the variable ‘p’ which the tutorial uses to increment through the arrays. The ‘i’ variable is initially used in the loop and won’t do us any good since the ‘p’ variable changes as the user flips through pictures.

just change the ‘i’ to ‘p’ in Project 107’s code and reference your array.
