You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xalan.apache.org by dm...@apache.org on 2002/03/05 22:15:41 UTC
cvs commit: xml-xalan/test/tests/conf/expression expression06.xsl expression06.xml
dmarston 02/03/05 13:15:41
Added: test/tests/conf/expression expression06.xsl expression06.xml
Log:
More elaborate lang() testing
Revision Changes Path
1.1 xml-xalan/test/tests/conf/expression/expression06.xsl
Index: expression06.xsl
===================================================================
<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<!-- FileName: expression06 -->
<!-- Document: http://www.w3.org/TR/xpath -->
<!-- DocVersion: 19991116 -->
<!-- Section: 4.3 -->
<!-- Purpose: Test of lang() function in a for-each -->
<xsl:template match="doc">
<out>
<xsl:for-each select="//para[lang('en')]">
<xsl:value-of select="@id"/>
<xsl:text>:</xsl:text>
<xsl:value-of select="ancestor-or-self::*[@xml:lang]/@xml:lang"/>
<xsl:if test="position() != last()">
<xsl:text>, </xsl:text>
</xsl:if>
</xsl:for-each>
</out>
</xsl:template>
</xsl:stylesheet>
1.1 xml-xalan/test/tests/conf/expression/expression06.xml
Index: expression06.xml
===================================================================
<?xml version="1.0" encoding="ISO-8859-1"?>
<doc>
<para id="1" xml:lang="en">en</para>
<div xml:lang="en">
<para id="2">en</para>
</div>
<para id="3" xml:lang="EN">EN</para>
<para id="4" xml:lang="en-us">en-us</para>
<para id="A" xml:lang="it">it</para>
<div xml:lang="it">
<para id="B">it</para>
</div>
<para id="C" xml:lang="IT">IT</para>
<para id="D" xml:lang="it-it">it-it</para>
</doc>
---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-cvs-help@xml.apache.org