XSLT transformation problem

I have a DITA topic which I am transforming into another topic.  I do this with XLST v1. using the javax.xml.transform classes.  When I use <xsl:copy />, the output document has xmlns:ditaarch= atrributes on the elements being copied.  The Open Toolkit (1.4.2.1) does not allow this to build.  How can I either prevent the attribute, or tell the OT to allow it.  I have tried adding name space to the style sheet,changing the default name space of the style sheet but cannot prevent the namespace attribute appearing in at least 1 element.

Thank you

 

Thank you for the solution - exactly what I needed.

Instead of xsl:copy, use xsl:element to construct the result element, e.g.:

<xsl:element name="{name(.)}>
<xsl:apply-templates/>
</xsl:element>