Last active
June 15, 2018 17:34
-
-
Save anarchivist/04dead482831de09f0091573ea97211e to your computer and use it in GitHub Desktop.
Strip OAC attributes from EAD
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<xsl:stylesheet version="1.0" | |
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"><xsl:output indent="yes"/><xsl:param name="removeAttributesNamed" select="'|C-ORDER|MAX-C-ORDER|score|cdlpath:parent|cdlpath:grandparent|xmlns:cdlpath|'"/><xsl:template match="node()|@*" name="identity"><xsl:copy><xsl:apply-templates select="node()|@*"/></xsl:copy></xsl:template><xsl:template match="@*"><xsl:if test= "not(contains($removeAttributesNamed, concat('|', name(), '|') ) ) "><xsl:call-template name="identity"/></xsl:if></xsl:template></xsl:stylesheet> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment