I’m wondering how I can return only a portion of XML data up to the next h2 tag. So I have xml node called SUMMARY as shown below with some example text:
 <SUMMARY>
  <h2>heading One</h2><p>paragraph text under heading one</p>
  <h2>Heading Two</h2><p>paragraph text under heading two</p>
  <h2>Heading Three</h2><p>paragraph text under heading three</p>       
 </SUMMARY>
I currently am using this but it's not quite working
         <xsl:choose>
          <xsl:when test="contains(SUMMARY, ':')">
            <xsl:value-of select="substring-before(SUMMARY, '.')"/>.
            </xsl:when>
          </xsl:choose>
Any help would be appreciated
paragraph text under heading two
is the expected result. I'm using a Content management system so I'm not sure which processor it uses - I'm using an xml datasource which connects to a xsl file. – NickP Aug 03 '17 at 02:30