# Really weird XML problem

**URL:** https://forum.kirupa.com/t/really-weird-xml-problem/120034
**Category:** Uncategorized
**Created:** [August 20, 2004, 2:20am UTC](https://forum.kirupa.com/t/really-weird-xml-problem/120034 "2004-08-20T02:20:11Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![APDesign](https://avatars.discourse-cdn.com/v4/letter/a/e47c2d/32.png) [@APDesign](https://forum.kirupa.com/u/APDesign)
#### Post date: [August 20, 2004, 2:20am UTC](https://forum.kirupa.com/t/really-weird-xml-problem/120034/1 "2004-08-20T02:20:11Z")

</div>

Ok, I’m new to XML with flash and I’ve looked at the tutorials and I have no clue what is going on here.

Heres part of my xml structure.

```auto

<?xml version="1.0"?>
	<guestbook>
		<entry>
			<hed headFrame="1" />
			<face faceFrame="1" />
			<hat hatFrame="1" />
			<shoe shoeFrame="1" />
			<name>Dujodu</name>
			<email>Weibmaster@dujodu.com</email>
			<website>http://www.dujodu.com/</website>
			<message>Hey this is a kind of cool guestbook you have going here.</message>
		</entry>
		<entry>
			<head headFrame="2" />
			<face faceFrame="2" />
			<hat hatFrame="2" />
			<shoe shoeFrame="2" />
			<name>Duder</name>
			<email>Webmaster@duder.net</email>
			<website>http://www.duder.net/</website>
			<message>Hey this is a kind of lameass guestbook you have going here. Keep up the crappy work.</message>
		</entry>
	</guestbook>

```

Ok, now I want to access the “headFrame” of the first entry, my AS would look like this, right?

```auto

hframe = my_xml.childNodes[0].childNodes[0].childNodes[0].attributes.headFrame;
trace(hframe);

```

That indeed should give me “1” shouldn’t it? Well I get undefined.

Through some trial and error, I found out that to get to the headFrame I need to use

```auto

hframe = my_xml.childNodes[1].childNodes[1].childNodes[1].attributes.headFrame;
trace(hframe);

```

which isn’t even right… so I have no clue what’s going on, but I figure that this will give me the face frame if it worked for the headFrame.

```auto

fframe = my_xml.childNodes[1].childNodes[1].childNodes[2].attributes.faceFrame;
trace(fframe);

```

well it doesn’t work, but guess what DOES work for the face frame

```auto

fframe = my_xml.childNodes[1].childNodes[1].childNodes[3].attributes.faceFrame;
trace(fframe);

```

how weird is that? So at this point I’m fed up and come to you guys for help… I hope you can make more sense of it than me…

---

<div class="post-metadata">

### Author: ![senocular](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/senocular/32/7217_2.png) [@senocular](https://forum.kirupa.com/u/senocular)
#### Post date: [August 20, 2004, 9:37am UTC](https://forum.kirupa.com/t/really-weird-xml-problem/120034/2 "2004-08-20T09:37:30Z")

</div>

my\_xml.ignoreWhite = true;

---

<div class="post-metadata">

### Author: ![APDesign](https://avatars.discourse-cdn.com/v4/letter/a/e47c2d/32.png) [@APDesign](https://forum.kirupa.com/u/APDesign)
#### Post date: [August 20, 2004, 3:18pm UTC](https://forum.kirupa.com/t/really-weird-xml-problem/120034/3 "2004-08-20T15:18:14Z")

</div>

> [@senocular](#):
>
> my\_xml.ignoreWhite = true;

Oh man, now I feel like a total moron

> [@My\_Code](#):
>
> myXML.igoreWhite = true;

no underscore, wrong case, not even in the right spot AND a typo… I was totally looking in the wrong spot to solve this problem :sure:

Thanks for the help!

btw, can’t wait for your new XML tutorials :thumb:

---

<div class="post-metadata">

### Author: ![senocular](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/senocular/32/7217_2.png) [@senocular](https://forum.kirupa.com/u/senocular)
#### Post date: [August 20, 2004, 3:37pm UTC](https://forum.kirupa.com/t/really-weird-xml-problem/120034/4 "2004-08-20T15:37:42Z")

</div>

Originally Posted by My\_Code :lol:

it happens. I still do it all the time - both things 😉

---

<div class="post-metadata">

### Author: ![foolicious](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/foolicious/32/715_2.png) [@foolicious](https://forum.kirupa.com/u/foolicious)
#### Post date: [August 24, 2004, 2:17pm UTC](https://forum.kirupa.com/t/really-weird-xml-problem/120034/5 "2004-08-24T14:17:58Z")

</div>

Definitely, I tend to forget it too. We should have it on bumper stickers or something. 😉
