RE: doctype on HTML document with xt and saxon

Subject: RE: doctype on HTML document with xt and saxon
From: Kay Michael <Michael.Kay@xxxxxxx>
Date: Fri, 3 Dec 1999 18:20:41 -0000
> Am I being very dense? Given this stylesheet:
> 
> <xsl:stylesheet
>   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"; 
>   version="1.0"
>   xmlns:xt="http://www.jclark.com/xt";
>   xmlns:saxon="http://icl.com/saxon";
>   extension-element-prefixes="saxon xt">
> 
> <xsl:output method="html"  
>  doctype-public="-//W3C//DTD HTML 4.0 Transitional//EN"/>
> 
> I expect to see a DOCTYPE before the <html>. When I run xt, I get
> 
> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
>  <html xmlns:saxon="http://icl.com/saxon";>
> 
> and when I get saxon I get 
> 
> <html>
> 
Regarding <!DOCTYPE>, SAXON is wrong. It is applying the method="xml" rule
that doctype-public is ignored unless doctype-system is also specified. This
rule should not be applied when method="html". Congratulations on finding
the first bug.

As regards the output of namespace declarations on literal result elements,
I believe SAXON is correct: section 7.1.1 says that the created element node
will have a copy of any namespace node other than XSLT, a namespace declared
as an extension namespace, or an excluded namespace.

Mike


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


Current Thread