Subject: RE: [xsl] Tricky White Spaces being ignored From: Jarno.Elovirta@xxxxxxxxx Date: Mon, 1 Mar 2004 08:40:40 +0200 |
Hi, > I have the following (example) template rule(s) along with > the outputed > result (surrounded by ==== to show where output begins and ends: > > <xsl:template match="br"> </xsl:template> > ====Dear Mr. Schmidt, We would like to take this opportunity to...==== > > <xsl:template match="br"> x</xsl:template> > ====Dear Mr. Schmidt, > > x > xWe would like to take this opportunity to...==== > > <xsl:template match="br"> x</xsl:template> > ====Dear Mr. Schmidt, > xWe would like to take this opportunity to...==== > > (last example is closest to right) > > NOTE: The only way I get these or to create a > line break in my > textarea is if I include a real character (character "x" above) in the > template rule. Then it works fine. What gives? It is > almost like the > template rule is ignored otherwise. The white space is stripped, see <http://www.w3.org/TR/xslt#strip>. Wrap the LINE FEED character into xsl:text: <xsl:template match="br"> <xsl:text>
</xsl:text> </xsl:template> Cheers, Jarno XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] Tricky White Spaces being ign, Karl J. Stubsjoen | Thread | RE: [xsl] Tricky White Spaces being, Karl J. Stubsjoen |
[xsl] Tricky White Spaces being ign, Karl J. Stubsjoen | Date | RE: [xsl] Transactions on Inventory, Jarno . Elovirta |
Month |