This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
RE: Template Question
- To: "'xsl-list at mulberrytech dot com'" <xsl-list at mulberrytech dot com>
- Subject: RE: Template Question
- From: "Selva, Francis" <Francis dot Selva at purchasepro dot com>
- Date: Thu, 27 Apr 2000 15:26:08 -0700
- Reply-To: xsl-list at mulberrytech dot com
> The reason this isn't working for you--
>
> ><xsl:template name="Chap3">
> ><Chap3Text><xsl:value-of select="."/></Chap3text><BR>
> ></xsl:template>
>
> is that the template is copying into your result tree the
> string value of
> the node matched ... which is to say, all its text content,
> but providing
> special handling for none of the elements below it in the hierarchy.
>
> Turn it and the others into
>
> <xsl:template name="Chap3">
> <Chap3Text><xsl:apply-templates/></Chap3text><BR>
> </xsl:template>
>
> and you should be in business.
>
> All your HL elements will be changed into B elements by your rule,
>
> ><xsl:template match="HL">
> ><B><xsl:value-of select="."/></B>
> ></xsl:template>
>
> although once again this will not provide for processing of
> any descendant
> elements of HL. Change this one to <xsl:apply-templates/>,
> too, if you want
> to support that.
>
>
> Try it out and see if the lights go on ... most new users of
> XSL have to
> have an "aha!" or two. Hoping that helps,
>
> Wendell Piez
Im one of those who said *aha*.lol.That was really helpful wendell.
Thanx
Francis
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list