RE: [xsl] Default namespace matching

Subject: RE: [xsl] Default namespace matching
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Fri, 29 Dec 2006 17:53:19 -0000
> I think I must be misunderstanding something fundamental 
> about namespaces.  Is it not the case that if your source 
> file has a default namespace, in order to get the stylesheet 
> to match, all you have to do is include the same namespace in 
> the declaration?  

No (or is it yes?), this is not the case.

Just search for "FAQ XSLT default namespace".

To match elements that are in a namespace, the element names in a path
expression need to be prefixed with a prefix bound to that namespace. The
default namespace from the stylesheet context is not used.

Michael Kay
http://www.saxonica.com/

Current Thread