View Single Post
  #2 (permalink)  
Old April 8th, 2008, 12:45 PM
Martin Honnen Martin Honnen is offline
Friend of Wrox
Points: 6,676, Level: 34
Points: 6,676, Level: 34 Points: 6,676, Level: 34 Points: 6,676, Level: 34
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Nov 2007
Location: Germany
Posts: 1,243
Thanks: 0
Thanked 245 Times in 244 Posts
Default

Code:
<xsl:template match="article">
  <xsl:apply-templates
    select="*[following-sibling::text()[. = 'My TEXT']]" mode="mode1"/>
  <xsl:apply-templates select="text()[. = 'My TEXT']"/>
  <xsl:apply-templates
    select="*[preceding-sibling::text()[. = 'My TEXT']]" mode="mode2"/>
</xsl:template>
--
  Martin Honnen
  Microsoft MVP - XML
Reply With Quote