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

listing elements & sub-elements in a seqence - skiping

Subject: listing elements & sub-elements in a seqence - skiping elemts if sub-elemts are present
From: Karl <call14@xxxxxxxxx>
Date: Tue, 25 Jul 2006 11:45:50 +0100 (BST)
seqence
Thanks David / Charles for the reply and yes the code <xsl:for-each
select="//Session/Section[not(SubSection)] |
//Session/Section/SubSection"/> worked. Infact I did tried this
before writing to the list but an spelling err from my side made me
to think the code was wrong. Sorry. 

But after seeing Chris's reply, I have a q

<xsl:for-each select="//Section[not(SubSection)] |
//Section/SubSection"/>
is definetly giving me the correct order of section and subsection
info that i wanted.

will charles's suggestion,

<xsl:template match="section[not(subsection)]">
 ...
</xsl:template>

& 

<xsl:template match="section[subsection]">
 ...
</xsl:template>

Then simply apply-templates, WILL GIVE THE RESULTS IN SAME ORDER as
that of for-each? [Pls note my actual reqmt is to generate pages with
specific name order and list them in specific order with links etc.
But I have simplified here to get the essence that I expect to
acheive] i.e,

<Section/>  will become  1.Section title in list + creat pg 1
<Section/>  
<Section/>  will become list num 3.Section title & pg 3

<Section>  ** [No pagebreaks/pagenums SINCE IT HAS <subsection> 
 <SubSection/>  So, this become 4. Subsection title (pg 4) 
 <SubSection/>  
 <SubSection/>  will become 6. Subsection title (pg 6)
<Section>  
and so on?

Thanks
karl


	
	
		
___________________________________________________________ 
All new Yahoo! Mail "The new Interface is stunning in its simplicity and ease of use." - PC Magazine 
http://uk.docs.yahoo.com/nowyoucan.html

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.