2012-02-09 3 views
0

select="document('02.xml')/*/Person"/select="document('04.xml')/*/Person"/はxslでどうやってチェックできますか? xslが実行中の場合xslで確認書類がどのように入手できますか?

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> 
    <xsl:output method="xml" indent="yes"/> 

    <xsl:template match="/xmlResponse"> 
     <xsl:copy> 
      <xsl:apply-templates select="document('02.xml')/*/Person"/> 
      <xsl:apply-templates select="document('04.xml')/*/Person"/> 
     </xsl:copy> 
    </xsl:template> 

    <xsl:template match="@* | node()"> 
     <xsl:copy> 
      <xsl:apply-templates select="@* | node()"/> 
     </xsl:copy> 
    </xsl:template> 
</xsl:stylesheet> 

答えて

0

XSLTプロセッサに依存します。その後、

最初のパーサ

<xsl:variable name="vendor" select="system-property('xsl:vendor')" /> 

チェックして選択します。

マイクロソフト使用埋め込まれたJavaScriptのカスタム機能(http://dev.ektron.com/kb_article.aspx?id=482)、FileSystemObjectオブジェクトを使用して、XSLTで試験することができる1または0を返します。

サクソン、Xalanの:

<xsl:variable name="d03" select="document('03.xml')"/> 
<xsl:choose> 
<xsl:when test="$d03"> 
     <xsl:apply-templates select="document('03.xml')/*/Person"/> 
</xsl:when> 
<xsl:otherwise> 
     <Person name="Matthew" missing="true"/> 
</xsl:otherwise></xsl:choose> 
関連する問題