This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: XSLT stylesheet highlighter / whitespace with output method html




There is nobody to blame but me. With <xsl:output method="html"
indent="no"/> xt, saxon and xalan produces, viewed with a browser, the
same result, as expected. You're absolutely right, according to the
standard indenting is on by default for html output; I overlooked
that.

So the mailed stylesheet - with this correction - may be a nice and
easy tool to produce some highlighted HTML Version of XSL stylesheets
only with xslt, for online documentation or whatever. Have fun with
it.

Greetings, rolf
rolf@pointsman.de


On 19 Mar, Scott_Boag@lotus.com wrote:
> rolf@pointsman.de wrote:
>> The intresting thing about it is that with <xsl:output method="text"/>
>> xt and saxon produce nearly the same output. Why isn't this true for
>> HTML output?
> 
> 1) indenting is on by default.  Different processors can handle indenting
> differently, as long as they do not mess with "significant" whitespace.  2)
> HTML has a lot of odd rules about whitespace handling that must be delt
> with on an element-by-element basis.  Most HTML serializers have the
> equivelent of an HTML DTD that help them do this.  The bottom line is that
> the whitespace handling rules for HTML are much more complex than for
> serializing a tree into XML.
> 
> -scott



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

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]