Re: [xsl] newline white space

Subject: Re: [xsl] newline white space
From: "Lisa Rupe" <LRupe@xxxxxxxxxxx>
Date: Thu, 19 Jul 2001 20:27:16 -0500
Thanks, Jeni.
This solved my problem for the hyphenated words, but where ever there were
other tags in the string, I lost my spaces.
How can I fix this?

<p>This is a <b>bold</b> para&#xAD;<lb/>

Displays as:
 This is aboldparagraph.

<xsl:template match="text()">
  <xsl:value-of select="normalize-space()" />

<xsl:template match="lb">
  <xsl:variable name="text" select="preceding-sibling::text()[1]" />
  <xsl:if test="substring($text, string-length($text)) != '&#xAD;'">
      <xsl:text> </xsl:text><xsl:apply-templates />

 XSL-List info and archive:

Current Thread