Subject: Re: [xsl] How to preserve white space of a title line From: Mike Brown <mike@xxxxxxxx> Date: Mon, 9 Apr 2001 13:53:56 -0600 (MDT) |
>1 use param to define a title line, such as ><xsl:param name="titleLine" select="Annual report for xxxx"/> You forgot the single quotes to indicate that it is a string rather than a node-set. <xsl:param name="titleLine" select="'Annual report for xxxx'"/> I see no reason why this wouldn't work. The default value of $titleLine will be the string with all the spaces intact. As Trevor indicated, perhaps you are emitting this string in an HTML document and are confused by the fact that runs of whitespace in HTML constitute a single word separator and are thus rendered with a single space in Western writing scripts. You didn't say what the problem really was. <xsl:value-of select="translate($titleLine,' ',' ')"/> may be of some utility for you. - Mike _____________________________________________________________________________ mike j. brown, software engineer at | xml/xslt: http://skew.org/xml/ webb.net in denver, colorado, USA | personal: http://hyperreal.org/~mike/ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] How to preserve white spa, Trevor Nash | Thread | [xsl] Confusion about preceding-sib, SCOTT, Darren, FM |
RE: [xsl] inserting space in xsl:va, Java XML | Date | Re: [xsl] inserting space in xsl:va, Steve Muench |
Month |