[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

test for child element

Subject: test for child element
From: ms <mina_hurray@xxxxxxxxx>
Date: Wed, 20 Dec 2006 08:22:22 -0800 (PST)
 test for child element
Hi all:

I am having issues with testing for the first child
element in an xml.
My xml looks like this:

<root>

  <level1>
        <note><para>First note</para></note>
         <note><para>Second note</para></note>
         <note><para>third note</para></note>
     <text>Some text</text>

  </level1>

Under <level1> template I am checking to see if the
first child element is a "note" and then displaying
it. 
How do I check to see if the following elements are
also "note" elements? If they are then I want them to
be displayed int he following format:

First note
Second note
Third note

1 Some text

But when i use <xsl:if test"child::*[1][self::note]">
it checks only for the first note. How do I make it
check if there are any more notes after the first
note?

Thanks in advance for your help.



__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.