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

Re: selecting a element without it's child element

Subject: Re: selecting a element without it's child element
From: pankaj.c@xxxxxxxxxxxxxxxxxx
Date: Thu, 11 Nov 2010 08:34:09 +0530
Re:  selecting a element without it's child element
>Pankaj has seen one example of 
>your input data, and leapt to the conclusion that all other examples 
>will be the same.

Michael is quite right. I just tried to give a clue to get the job done. 
Though it will fail in case if you xml seems like 

<book><title><indexterm>Violent Extremism</indexterm> Sacred Values, and 
what it Means <indexterm>to be Human</indexterm></title></book>

I believe that you are trying to ignore text, whatever appears in child 
element <indexterm>. For that I would suggest to use template rules, which 
already suggested to you:

<xsl:template match="title">
<xsl:apply-templates/>
</xsl:template>

Suppress the indexterm:

<xsl:template match="indexterm"/>

Thanks for pointing that Michael.

--Pankaj

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.