Re: horizontal tabs and parsing strings

Subject: Re: horizontal tabs and parsing strings
From: Earl Bingham <earl@xxxxxxxxx>
Date: Tue, 30 Nov 1999 13:38:57 -0800
I solved my own problem a little after I posted. You need to use the
syntax: <xsl:variable name="myTab" select="'    '"/> were you have
quote and single tick put together for the variable. Then I can parse
strings for values that are broken up with tabs.

- Earl

Earl Bingham wrote:

> 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


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


Current Thread