Re: [xsl] IE Client side transformation issue

Subject: Re: [xsl] IE Client side transformation issue
From: "Manfred Staudinger" <manfred.staudinger@xxxxxxxxx>
Date: Fri, 3 Aug 2007 16:55:01 +0200
On 03/08/07, Abel Braaksma <abel.online@xxxxxxxxx> wrote:
> Because you seem to try to create XHTML from an XSLT 1.0 processor
> you've to manually make sure that the tags keep their closing tags. A
> non-breaking space is not such a good solution, I think, because it may
> influence the rendering results. Rather, you should choose the comment
> approach:
>
> <xsl:template match="somenode">
>    <div><xsl:comment>i am empty</xsl:comment></div>
> <xsl:template>
Some time ago I have tested this situation in IE 6 and IE 7 and found
using xsl:output method="html" or "xml" seems to make no difference
here. What makes a difference is whether the element comes from the
input doc or from the stylesheet:
a. If you have <div style="display: none"/> in the input doc, it becomes
<div style="display: none">CRLF</div> after being copied by
<xsl:apply-templates/>
b. If you have <div style="display: none"/> in your stylesheet, it becomes
<div style="display: none" /> in the output (invalid html). To avoid
this simply
code <div style="display: none"></div>.

You may check this (and a few other things) with
http://test.rudolphina.org/Test_IE.xml

Manfred

Current Thread