title: Need to replace the tag along with quotes using XSLT
body: <p>I want to add  element inside the quotes, but its not coming if i used this XSLT and I'm using saxon PE 9.6.0.7 and version=2.0 in XSL</p>
  
  <p>My Input xml file:</p>
  
  <pre><code>&lt;text_top&gt;
  &lt;p&gt;Insulin is a medicine that is now an important part of your treatment plan. But you’re probably wondering, why now? Is my diabetes getting worse? Remember, with&lt;/p&gt;
  &lt;/text_top&gt;
  &lt;text_bottom&gt;
  &lt;p&gt;So, to try and lower your blood glucose levels, your pancreas works overtime to get more insulin into your bloodstream, even though this insulin&lt;/p&gt;
  &lt;p&gt;As result, blood glucose levels increase, the pancreas eventually wears out, and the cells that produce the insulin in your pancreas are destroyed.&lt;/p&gt;
  &lt;/text_bottom&gt;
  </code></pre>
  
  <p>XSL I used as:</p>
  
  <pre><code>    &lt;xsl:stylesheet version="3.0" 
          xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
          xmlns:xs="http://www.w3.org/2001/XMLSchema"
          xmlns:json="http://json.org/" xmlns:mf="http://example.com/mf"
          exclude-result-prefixes="#all"&gt;
  
  &lt;xsl:template match="text_top"&gt;
      "top": "&lt;xsl:sequence select="mf:break(normalize-space(string-join(node()/serialize(., $ser-params), '')))"/&gt;",
  &lt;/xsl:template&gt;
  
  &lt;xsl:template match="text_bottom"&gt;
      "bottom": "&lt;xsl:sequence select="mf:break(normalize-space(string-join(node()/serialize(., $ser-params), '')))"/&gt;",
  &lt;/xsl:template&gt;
  
          &lt;xsl:param name="length" as="xs:integer" select="80"/&gt;
  
          &lt;xsl:param name="pattern" as="xs:string" select="concat('((.{1,', $length, '})( |$))')"/&gt;
  
          &lt;xsl:param name="sep" as="xs:string" select="' +&amp;#10; '"/&gt;
  
          &lt;xsl:function name="mf:break" as="xs:string"&gt;
              &lt;xsl:param name="input" as="xs:string"/&gt;
              &lt;xsl:variable name="result"&gt;
                  &lt;xsl:analyze-string select="$input" regex="{$pattern}"&gt;
                      &lt;xsl:matching-substring&gt;
                          &lt;xsl:value-of select="concat('&amp;quot;', regex-group(2), '&amp;quot;')"/&gt;
                          &lt;xsl:if test="position() ne last()"&gt;
                              &lt;xsl:value-of select="$sep"/&gt;
                          &lt;/xsl:if&gt;
                      &lt;/xsl:matching-substring&gt;
                  &lt;/xsl:analyze-string&gt;
              &lt;/xsl:variable&gt;
              &lt;xsl:sequence select="$result"/&gt;
          &lt;/xsl:function&gt;
  
  
      &lt;/xsl:stylesheet&gt;
  </code></pre>
  
  <p>I got the output json as:</p>
  
  <pre><code>"top": "&lt;p&gt;Insulin is a medicine that is now an" +
  "important part of your treatment plan. But" +
  "you’re probably wondering, why now? Is my" + 
  "diabetes getting worse? Remember, with&lt;/p&gt;",
  
  "bottom": "&lt;p&gt;So, to try and lower your blood glucose" + 
  "levels, your pancreas works overtime to" +
  "get more insulin into your bloodstream, even" + 
  "though this insulin&lt;/p&gt;&lt;p&gt;As result, blood glucose levels" +
  "increase, the pancreas eventually wears out, and the cells" +
  "that produce the insulin in your pancreas are destroyed.&lt;/p&gt;"
  </code></pre>
  
  <p>But I expecting the json output as:</p>
  
  <pre><code>"top": "&lt;span&gt;Insulin is a medicine that is now an" +
  "important part of your treatment plan. But" +
  "you’re probably wondering, why now? Is my" + 
  "diabetes getting worse? Remember, with&lt;/span&gt;",
  
  "bottom": "&lt;span&gt;So, to try and lower your blood glucose" + 
  "levels, your pancreas works overtime to" +
  "get more insulin into your bloodstream, even" + 
  "though this insulin&lt;/span&gt;"
  
  "&lt;span&gt;As result, blood glucose levels" +
  "increase, the pancreas eventually wears out, and the cells" +
  "that produce the insulin in your pancreas are destroyed.&lt;/span&gt;"
  </code></pre>
  
  <p>Please advice me on this, Thanks in advance.</p>