# XML parsing question

**URL:** <https://forum.kirupa.com/t/xml-parsing-question/79999>\
**Category:** programming\
**Created:** [February 18, 2005, 2:31pm UTC](https://forum.kirupa.com/t/xml-parsing-question/79999 "2005-02-18T14:31:57Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![dante2010](https://avatars.discourse-cdn.com/v4/letter/d/cdc98d/32.png) [@dante2010](https://forum.kirupa.com/u/dante2010)\
**Post date:** [February 18, 2005, 2:31pm UTC](https://forum.kirupa.com/t/xml-parsing-question/79999/1 "2005-02-18T14:31:57Z")

</div>

[font=verdana, arial, helvetica][size=2]I want to parse the image names in the following XML into an array:

\<?xml version=“1.0” encoding=“UTF-8” ?\>

- \<ride\>
- \<gallery\>  
\<image\>1\_gallery\_1.jpg\</image\>  
\<image\>1\_gallery\_2.jpg\</image\>  
\<image\>1\_gallery\_3.jpg\</image\>  
\<image\>1\_gallery\_4.jpg\</image\>  
\<image\>1\_gallery\_5.jpg\</image\>  
\<image\>1\_gallery\_6.jpg\</image\>  
\<image\>1\_gallery\_7.jpg\</image\>  
\<image\>1\_gallery\_8.jpg\</image\>  
\</gallery\>  
\</ride\>

What would the variable name be to get to the start of the image names?

IE: this.firstChild.childNodes.childNodes[0].firstChild.nodeValue

I’m having a really hard time figuring this out.[/size][/font]
