# Xpath question

**URL:** <https://forum.kirupa.com/t/xpath-question/249903>\
**Category:** Uncategorized\
**Created:** [January 23, 2008, 4:12pm UTC](https://forum.kirupa.com/t/xpath-question/249903 "2008-01-23T16:12:32Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![abhikumar](https://avatars.discourse-cdn.com/v4/letter/a/67e7ee/32.png) [@abhikumar](https://forum.kirupa.com/u/abhikumar)\
**Post date:** [January 23, 2008, 4:12pm UTC](https://forum.kirupa.com/t/xpath-question/249903/1 "2008-01-23T16:12:32Z")

</div>

this is new for me- need some help here…

when im using:  
[COLOR=darkred]\_root.mytxt.htmlText=XPathAPI. **selectNodeList** (this.firstChild, “/rss/channel/item/title”);[/COLOR]  
what should i do to view **title 1 to 5** \*\*only \*\*from the xml file ( **currntly displays all titles** )

for:  
[COLOR=darkred]\_root.mytxt.htmlText=XPathAPI. **selectSingleNode** (this.firstChild, “/rss/channel/item/title”);[/COLOR]  
what should i do to (randomly) **view the number 2 title** from the xml file ( **currntly displays number 1 title only** )

thank u so very much.
