[xsl] XHTML result validation using xsl:type

Subject: [xsl] XHTML result validation using xsl:type
From: "Andrew Welch" <andrew.j.welch@xxxxxxxxx>
Date: Thu, 31 Jan 2008 16:49:59 +0000
Given this setup:



<xsl:template match="/">
  <html xsl:type="html">

This currently causes the error:

There is no type named html in an imported schema
URL: http://www.w3.org/TR/xslt20/#err-XTSE1520

But using xsl:validation="strict" works without error.

<xsl:template match="/">
  <html xsl:validation="strict">

I'm guessing it's some problem with the default namespace, but I
thought this should work.

The spec says:
"The [xsl:]type attribute takes as its value a QName. This must be the
name of a type definition included in the in-scope schema components
for the stylesheet. If the QName has no prefix, it is expanded using
the default namespace established using the effective
[xsl:]xpath-default-namespace attribute if there is one; otherwise, it
is taken as being a name in no namespace."


Should xsl:type work as expected here, or am I missing something?

Using Saxon 9.0.

Andrew Welch
Kernow: http://kernowforsaxon.sf.net/

Current Thread