>Hi all, > >I am using   in my sheets to insert a whitespace- >however, in Michael Kay's excellent book, I came >across  . They look like they do the same thing, >but which is a more standard way of inserting an > in the resulting HTML? > They are exactly the same thing, i.e. the non-breaking space character. I get the impression   is used more often, but I would not lose sleep over it. >Also, do you think doing the following approach is >better than the previous ones? > ><xsl:variable name="space"> ><xsl:value-of select=" ' ' " /> ></xsl:variable> > >Now use $space to insert up to one space character in >the resulting HTML. > I hope you don't mean $space as an alternative to   or &#A0;. A space (written ' ' or   or  ) is not the same character as a non-breaking space (written   or &#A0;). The other problem is you can't just say $space (or $nbsp) anywhere you like. You may end up having to put <xsl:value-of select="$space"/>. What you can do is put a DOCTYPE declaration at the top of your stylesheet, and define in it. Then just write instead of  . I'm sure this is in the FAQ somewhere - I'm not going to write it from the top of my head as I'm bound to ge it wrong. >I know this is not a very serious issue (meaning my >implementation does not depend very heavily on the >resolution of this issue) but any guidance will be >greatly appreciated. > >Thanks, >Cheers, >Alan. > -- Traditional training & distance learning, Consultancy by email Melvaig Software Engineering Limited voice: +44 (0) 1445 771 271 email: tcn@xxxxxxxxxxxxx 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