horizontal tabs and parsing strings

Subject: horizontal tabs and parsing strings
From: Earl Bingham <earl@xxxxxxxxx>
Date: Tue, 30 Nov 1999 10:03:54 -0800
I have been trying to determine if it is possible to parse a string with
tabs within the string. I have tried using a tab, the hexidecimal &#009;
and then CDATA value,
but none appeared to work. I was curious if anyone knows how it can be
done
with documents?

Thanks,

Earl

<xsl:stylesheet
  version="1.0"
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
   >

<xsl:template match="docRoot">

  <xsl:variable name='myTab'> </xsl:variable>
  <!--   <xsl:variable name='myTab'>&#0009;</xsl:variable> -->

    <!-- <xsl:variable name='myTab'><xsl:text
disable-output-escaping="yes"><![CDATA[ ]]></xsl:text></xsl:variable>
-->

  <xsl:variable name='tabbedString'
select="//paragraph[@style='HTAB2']/text"/>
  <xsl:variable name='beforeTab'><xsl:value-of
select="substring-before($tabbedString, $myTab)"/></xsl:variable>
  <when><xsl:value-of select="$tabbedString"/></when>
  <what><xsl:value-of select="$beforeTab"/></what>

</xsl:template>

</xsl:stylesheet>



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


Current Thread