RE: [xsl] tag minimisation

Subject: RE: [xsl] tag minimisation
From: "Andrew Welch" <andrew@xxxxxxxxxxxxxxxxxxxxxxx>
Date: Thu, 7 Feb 2002 08:47:36 -0000

>No it is entirely up to the system how it linearises empty elements:
>some XSLT systems use <p/> some <p></p> .Since every XML system will
>treet these identically it shouldn't matter which you get.

Well, it does matter.

I will give you some code:

<style>
  span p {margin-left:0em}
  p {margin-left:2.5em}
</style>
<body>
  <span></span>
  <p>Hello</p>
  <span/>
  <p>world</p>
</body>

The output you will get in IE5.5 is:

	Hello
World

The <p> after the minimised <span/> does not pick up its CSS style properly.
>From a few tests, I found that msxml2.6 converted <span></span> to <span/>
whilst MSXML3 and Instant Saxon left it as <span></span> (and not causing a
problem).

Ive tried converting the above to xhtml, but that doesnt solve the problem
either.

Has anyone had similar problems with tag minimisation, and any possible
solutions?



cheers

andrew

===



-----Original Message-----
From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx
[mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx]On Behalf Of David
Carlisle
Sent: Wednesday, February 06, 2002 5:02 PM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re: [xsl] tag minimisation



> whereas xsl proper keeps it as <p></p>.

No it is entirely up to the system how it linearises empty elements:
some XSLT systems use <p/> some <p></p> .Since every XML system will
treet these identically it shouldn't matter which you get.

David

_____________________________________________________________________
This message has been checked for all known viruses by Star Internet
delivered through the MessageLabs Virus Scanning Service. For further
information visit http://www.star.net.uk/stats.asp or alternatively call
Star Internet for details on the Virus Scanning Service.

 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