Subject: Re: Mixed content transformation From: Keith Visco <kvisco@xxxxxxxxx> Date: Thu, 14 Jan 1999 10:07:40 -0500 |
Paul, Here is one solution: <xsl:template match="foo"> <P><xsl:apply-templates/></P> </xsl:template> <xsl:template match="bar"> <B><xsl:apply-templates/></B> </xsl:template> you could also use: <xsl:template match="foo"> <P> <xsl:for-each select="bar"> <B><xsl:apply-templates/></B> </xsl:for-each> </P> </xsl:template> Paul_Tihansky@xxxxxxxxxxxx wrote: > > I have a simple question, but I couldn't find any references to it in > the XSL working draft. How can I transform mixed content using XSL? I > think I remember hearing that Microsoft can't handle it at this point, but > I didn't even see it covered in the working draft. > > For example, lets say I have this simple XML snippet: > <foo>This is <bar>mixed</bar> content.</foo> > > What would my XSL look like to transform this to: > <P>This is <B>mixed</B> content.</P> > > Am I missing something obvious? > > Thanks a bunch, > Paul > > XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Mixed content transformation, Paul_Tihansky | Thread | Re: Mixed content transformation, Guy_Murphy |
Re: GOTCHA!, Oren Ben-Kiki | Date | Re: Mixed content transformation, Guy_Murphy |
Month |