# Attribute Issues

**URL:** <https://forum.kirupa.com/t/attribute-issues/256363>\
**Category:** flash\
**Created:** [April 2, 2008, 2:21pm UTC](https://forum.kirupa.com/t/attribute-issues/256363 "2008-04-02T14:21:09Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Digitalosophy](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/digitalosophy/32/1114_2.png) [@Digitalosophy](https://forum.kirupa.com/u/Digitalosophy)\
**Post date:** [April 2, 2008, 2:21pm UTC](https://forum.kirupa.com/t/attribute-issues/256363/1 "2008-04-02T14:21:09Z")

</div>

Erm, trying to grab the attributes of a node, and can’t target it.

```auto

<?xml version="1.0"?>
<header>
  <scoreboard url="simpleScoreboard.jsp"/>
  <background>
       <folder url="media/headers/" count="10" prefix="header_bg_" suffix=".jpg" override="false" startTime="10" />
       <abc foreground="media/headers/abcForeground.swf" foreground2="media/headers/abcForeground2.swf" background="media/headers/abcBackground.swf" on="true" />
  </background>
  <ad>
      <geoTarget countryCode="US" swf="media/hdr_trades.swf" link="entry.point?target=z&source=foo" />
      <geoTarget countrycode="other" swf="" link="" />
  </ad>
</header>

```

The only data I need to parse is

```auto

  <ad>
      <geoTarget countryCode="US" swf="media/hdr_trades.swf" link="entry.point?target=z&source=foo" />
      <geoTarget countrycode="other" swf="" link="" />
  </ad>

```

The rest isn’t being used.

What’s annoying is

```auto

        for (attr in adXMLNode.firstChild.attributes) {
            trace(attr+" = "+adXMLNode.firstChild.attributes[attr]);
        }

```

Will trace the url attribute of the first node but I can’t find the correct targetting for the node I need.

I’ve been using AS 3 to do all my XML stuff but I can’t use AS 3 for this project unfortunately and I don’t really get it with AS 2.

Anyway any help would be huge right now.

Thanks guys!
