[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: How to preserve white space of a title line

Subject: Re: How to preserve white space of a title line
From: tcn@xxxxxxxxxxxxx (Trevor Nash)
Date: Mon, 09 Apr 2001 10:07:25 GMT
preserve white spaces
>Need help to use preseve-space element as following case;
>
>1  use param to define a title line, such as
><xsl:param name="titleLine" select="Annual    report    for    xxxx"/>
>There are  two or more white spaces between each word.
>
>2  Try to use <xsl:preserve-space>  commads but can not figure out how to
>use it,
>   since the attritute of presrve is for element.
>

It is hard to say what your problem is, but it will not be solved with
xsl:preserve-space.  This specifies what to do with white-space-only
nodes in the *source* document, such as in the following non-empty
element:
  <text>      </text>

Even then, it only has an effect if you are also using a
<xsl:strip-space> which matches the same element.

We need to know how you are using this parameter, and what output mode
you are using (html, xml, text?).  I can only think of two ways these
spaces could get lost:
  1) you are using the function normalize-space() on this value
  2) you are generating HTML, and are forgetting that browsers
generally display multiple spaces the same as a single space

Other guesses anyone?

HTH
Trevor Nash

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


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.