RE: [xsl] namespace issue?

Subject: RE: [xsl] namespace issue?
From: "Michael Kay" <michael.h.kay@xxxxxxxxxxxx>
Date: Wed, 14 Nov 2001 21:07:42 -0000
> I have a document with a first (mother-of-all-elements :-) in the
> following format:
>
> <DDDefinition xmlns="http://www.myside.site/ccc/ddd";
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
> xsi:schemaLocation="http://www.myside.site/ccc/ddd mySchema.xsd">

> I have an xslt which is processing this document and fails.
>
> <xsl:template match="DDDefinition">

You are looking for DDDefinition in the null namespace, this will not find
DDDefinition in the ..myside.site.. namespace: by definition, the names in
one namespace are quite unconnected with the names in another. You need to
write match="xx:DDDefinition" and set xmlns:xx="..myside.site..".

Mike Kay


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


Current Thread