substring-after demo : substring after « XSLT stylesheet « XML

Home
XML
1.CSS Style
2.SVG
3.XML Schema
4.XQuery
5.XSLT stylesheet
XML » XSLT stylesheet » substring after 
substring-after demo


File: Data.xml
<poem>
  <verse>line 1</verse>
  <verse>

    line 2

  </verse>
</poem>

File: Transform.xslt
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  version="1.0">
  <xsl:output method="xml" omit-xml-declaration="yes" indent="no" />
  <xsl:template match="verse">
    <xsl:value-of select="." />
    <xsl:value-of select="substring-after(.,'desolation')" />
  </xsl:template>

  
</xsl:stylesheet>
Output:


  line 1
  

    line 2

  

 
Related examples in the same category
1.substring-after() and text()
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.