1<?xml version="1.0"?> 2<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:libxslt="http://xmlsoft.org/XSLT/namespace" exclude-result-prefixes="libxslt" version="1.0"> 3 <xsl:output method="xml" indent="yes"/> 4 <xsl:variable name="one"> 5 <xsl:copy-of select="."/> 6 </xsl:variable> 7 <xsl:variable name="two" select="document('bug-65.ent')"/> 8 <xsl:template match="/"> 9 <xsl:apply-templates select="$two" mode="two"/> 10 </xsl:template> 11 <xsl:template match="*" mode="two"> 12 <xsl:for-each select="//content"> 13 <xsl:apply-templates select="libxslt:node-set($one)" mode="one"/> 14 <xsl:text> 15----------------- 16</xsl:text> 17 </xsl:for-each> 18 </xsl:template> 19 <xsl:template match="*" mode="one"> 20 <xsl:for-each select="//content"> 21<!-- here is the problem (.//content works well, but I need the key 22 function)--> 23 <xsl:copy-of select="."/> 24 </xsl:for-each> 25 </xsl:template> 26</xsl:stylesheet> 27