Page 1 of 1

XSLT transformation for schema documents

Posted: Thu Jan 26, 2006 9:38 pm
by martindholmes
Hi there,

I have some TEI P5 documents that start like this:

<TEI xmlns:xsi="" xsi:schemaLocation=" imt_p5.xsd" xmlns:svg="" xmlns="" version="5.0">

When I run an XSLT transformation on them, the transformer doesn't seem to find the root element; no templates are applied. However, when I remove the attributes:


the transformation works. Any idea why?


Posted: Thu Jan 26, 2006 10:32 pm
by george
Hi Martin,

In the first case you have more than attributes, you have also a default namespace declaration, the xmlns="..." which places the TEI element in the TEI P5 namespace. In the second case you have a TEI element in no namespace.

Now it seems that your stylesheet is prepared to handle TEI elements in no namespace and cannot handle TEI elements in the TEI P5 namespace.

Best Regards,