Re: [xsl] Selecting text bisected by child nodes.

Subject: Re: [xsl] Selecting text bisected by child nodes.
From: "Mike Haarman" <mhaarman@xxxxxxxxxxxxxxxxxx>
Date: Tue, 22 Apr 2003 15:06:18 -0500
From: "Gan Uesli Starling" <alias@xxxxxxxxxxx>

> An actual XML node is like this...
> 
> <op>pow(<in>2.0, -3</in>)</op>
> 

This template:

  <xsl:template match="op">
    <html>
      <body>
        <p><xsl:apply-templates mode="do-nothing"/></p>
      </body>
    </html>
  </xsl:template>

Relies on the existence of a do-nothing template for *in*:

  <xsl:template match="in" mode="do-nothing"/>

And returns your desired result wrapped in p tags.


hth,

Mike

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread