[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

RE: [xsl] Fwd: white space in MSIE


Subject: RE: [xsl] Fwd: white space in MSIE
From: "Dion Houston" <dionh@xxxxxxxxxxxxxxxxxxxxx>
Date: Mon, 2 Dec 2002 11:18:21 -0800

Interestingly, I was not able to repro this with MSXML (and hence IE).
I was able to repro this with System.Xml though.  I used the following
stylesheet:

<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
	<xsl:template match="/">
		<HTML>
			<HEAD><TITLE>TEST</TITLE></HEAD>
			<BODY><H1><xsl:value-of
select="normalize-space(/p)"/></H1></BODY>
		</HTML>
	</xsl:template>

</xsl:stylesheet>

Does anyone have the stylesheet he used to repro this behavior?

Thanks!

Dion 

-----Original Message-----
From: Wendell Piez [mailto:wapiez@xxxxxxxxxxxxxxxx] 
Sent: Monday, December 02, 2002 10:35 AM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: [xsl] Fwd: white space in MSIE

Hi folks,

On another list, the question below appeared regarding the way the 
processor handles whitespace.

Can someone confirm that what is being described stems from a bug in
MSXML? 
I'm recalling something about it but I'm not sure of the details....

Thanks--!
Wendell

>Sender: "TEI (Text Encoding Initiative) public discussion list"
>               <TEI-L@xxxxxxxxxxxxxxxxxx>
>From: "Rafal T. Prinke" <rafalp@xxxxxxxxxx>
>Subject:      white space in MSIE
>To: TEI-L@xxxxxxxxxxxxxxxxxx
>X-Loop-Detect: 1
>
>This question should perhaps be asked elsewhere - but I think
>it might be of interest to other TEIers.
>
>I intend to put some raw TEI/XML texts on-line to be browsed
>with MS IE. I am now struggling with XSLT stylesheets and
>encountered a problem of a single white space (ie. just a space)
>between two elements. For example:
>
><p>
>    Colonel
>      <persName>
>          <foreName>John</foreName> <surname>Smith</surname>
>      </persName>
>    was born in 1875.
></p>
>
>is displayed as:
>
>      Colonel JohnSmith was born in 1875.
>
>ie. with all spaces normalized except for the one which is
>the only character between two elements - with no textual data
>there.
>
>When the same fragment is transformed with Saxon, that space
>is preserved.
>
>Is there any easy way to achieve the desired effect in MS IE
>without changing the source?
>
>It can be done inserting the space *inside* one element:
>
>     <foreName>John </foreName><surname>Smith</surname>
>
>but I don't like this solution as intuitively the space
>does not belong in either of the two elements.
>
>Best regards,
>
>Rafal


======================================================================
Wendell Piez                            mailto:wapiez@xxxxxxxxxxxxxxxx
Mulberry Technologies, Inc.                http://www.mulberrytech.com
17 West Jefferson Street                    Direct Phone: 301/315-9635
Suite 207                                          Phone: 301/315-9631
Rockville, MD  20850                                 Fax: 301/315-8285
----------------------------------------------------------------------
   Mulberry Technologies: A Consultancy Specializing in SGML and XML
======================================================================


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


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



Current Thread
Keywords