Thanks Radu —  for restoring my faith :) Unchecking the “Add default attribute values” did indeed remove the unwanted attributes from the output.

All best,

Toma Tasovac | @ttasovac 
Belgrade Center for Digital Humanities

On Wed, Jun 17, 2015 at 9:47 AM, Radu Coravu <[log in to unmask]> wrote:

Hi Toma,

It's possible that those extra attributes are defined as having default
values in the schemas used to validate the TEI content.

Are those TEI XML documents DTD-based or Relax NG based?
If they are Relax NG based and you are using Oxygen XML Editor to apply
the XSLT you can go to the Preferences->"XML / XML Parser / RELAX NG"
page and uncheck the "Add default attribute values" checkbox.


Radu Coravu
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger

On 6/17/2015 10:41 AM, Toma Tasovac wrote:
> Dear list,
> I’m converting some TEI files and I am noticing an unusual thing. Even
> when I apply the basic recursive copy template such as:
> <xsl:template match="@*|node()">
> <xsl:copy>
> <xsl:apply-templates select="@*|node()"/>
> </xsl:copy>
> </xsl:template>
> most of the elements in my dictionary (entryFree, form, orth etc.)
> although not all (ref, rs) get mystery attributes in the output:
> opt=“false”
> which doesn’t exist in the original xml.
> Furthermore, in the otuput <orth> gets one more unwarranted attribute:
> extent=“full”
> I am using XSLT 2.0. My faith in the rational universe is shaken. Any
> idea where these attributes come from and how to suppress them?
> All best,
> Toma
> --
> Toma Tasovac | @ttasovac
> Belgrade Center for Digital Humanities