1
|
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
<!-- $Id: htm-tpl-lang.xsl 1858 2013-02-14 18:07:10Z simonastoyanova $ -->
|
3
|
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
4
|
xmlns:t="http://www.tei-c.org/ns/1.0" exclude-result-prefixes="t"
|
5
|
version="2.0">
|
6
|
<!-- Contains all language related named templates -->
|
7
|
|
8
|
<xsl:template name="attr-lang">
|
9
|
<xsl:if test="ancestor-or-self::t:*[@xml:lang]">
|
10
|
<xsl:attribute name="lang">
|
11
|
<xsl:value-of select="ancestor-or-self::t:*[@xml:lang][1]/@xml:lang"/>
|
12
|
</xsl:attribute>
|
13
|
</xsl:if>
|
14
|
</xsl:template>
|
15
|
|
16
|
</xsl:stylesheet>
|