+ <xsl:variable name="site" select="document(concat('../xml/sites/',@file,'.xml'))/site"/>
+ <xsl:choose>
+ <xsl:when test="$site/name">
+ <xsl:value-of select="$site/name"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="$site/subsite/name"/>
+ </xsl:otherwise>
+ </xsl:choose>