This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Re: testing child elements for text
- From: "Thomas B. Passin" <tpassin at mitretek dot org>
- To: <xsl-list at lists dot mulberrytech dot com>
- Date: Tue, 18 Jun 2002 17:30:38 -0400
- Subject: Re: [xsl] testing child elements for text
- References: <CF698667C737D41198E50060943F3CF6F68273@hoexch03.amica.com>
- Reply-to: xsl-list at lists dot mulberrytech dot com
[CROFT, MICHAEL]
> I need to see if an element has children that contain data....
>
> <InsClaimsAdverseClaimantContact Id="1-16J9D">
> <ListOfAmicaContactServiceProvider/>
> <ListOfInsClaimsAdverseClaimant/>
> </InsClaimsAdverseClaimantContact>
>
> What is a way to test if the parent element has any children that actually
> have data? I will only process the parent if it has children that contain
> data.
>
<xsl:apply-templates
select='InsClaimsAdverseClaimantContact[*]'/>
You might want to look at Michael Kay's post from a few hours ago (subject:
RE: [xsl] Best practices), too.
Cheers,
Tom P
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list