# XML question

**URL:** <https://forum.kirupa.com/t/xml-question/206888>\
**Category:** Uncategorized\
**Created:** [November 12, 2006, 9:25pm UTC](https://forum.kirupa.com/t/xml-question/206888 "2006-11-12T21:25:47Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![sottenad](https://avatars.discourse-cdn.com/v4/letter/s/b3f665/32.png) [@sottenad](https://forum.kirupa.com/u/sottenad)\
**Post date:** [November 12, 2006, 9:25pm UTC](https://forum.kirupa.com/t/xml-question/206888/1 "2006-11-12T21:25:47Z")

</div>

Hello, I’m having a problem and wondering if any of you have solved a similar one. Im using attachMovie to attach multiple instances of the MC “entry” to hold various news stories. What I’m trying to acheive is when you click on one of the entries, all the others dissapear and the entry you clicked on moves to a different place on the stage and gets bigger. The problem I’m having is I dont know how to apply a function to the right instance of “entry”. Any Ideas. Thanks

```auto
var home:MovieClip = this;
var news:XML = new XML();
news.ignoreWhite = true;
news.onLoad = function() {
    var nodes = this.firstChild.childNodes;
    numOfItems = nodes.length;
    for (var i = 0; i<numOfItems; i++) {
      var headline = home.attachMovie("entry", "entry"+i, i+1);
      headline._x = 35;
      headline._y = (i*68) + 75;
      headline.story.text = nodes*.attributes.story;
      headline.title.text = nodes*.attributes.headline;
      headline.onRelease = function(){
          headline.title.text = nodes*.attributes.story;
      }
     
    }
};

news.load("news.xml");

```

[Here is the FLA](http://www.steveottenad.com/FINAL.fla)  
[Here is the XML](http://steveottenad.com/news.xml)
