[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: nbsp (in parameter) question
> I am passing a parameter to a xsl stylesheet which outputs HTML. This > param is simply printed by the stylesheet. > > The problem is that the data i am passing to this param is something > like this > > UserName : XYZ nbsp;nbsp;nbsp;nbsp; Company Name : ZZZ > > That whole String is one parameter, and i want it to be > printed out like > this : > > UserName : XYZ Company Name : ZZZ > > Note, that it must be printed with spaces in between. > > I know i can replace nbsp; with   while passing the > parameter data. But this is not working. The output i get in > that case is : > > UserName : XYZ     Company Name : ZZZ > > The conversion of   to a space is not happening. > The conversion of   to a non-breaking space is done by an XML parser. When you pass a string as a parameter to the stylesheet, it is never processed by an XML parser, so XML character references are not substituted. You will have to work out how to generate a string containing this character in your chosen programming language: if you are using Java, you can write it as "\u00a0". Michael Kay Software AG home: Michael.H.Kay@xxxxxxxxxxxx work: Michael.Kay@xxxxxxxxxxxxxx XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|