Reporting the XSLT processor in xmlspec.xsl

View: New views
1 Messages — Rating Filter:   Alert me  

Reporting the XSLT processor in xmlspec.xsl

by Jonathan Robie-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


On the XQuery / XSL family of specs, we have lots of different operating
systems, JREs, and XSLT processors.

To make it a little easier to understand why different editors get
different results with the same stylesheets, I would like all of our
stylesheets to report the XSLT processor used.

I propose adding the following code to xmlspec.xsl.

Jonathan

  <!-- existing code -->
  <xsl:template match="/">
  <!-- proposed new -->
    <xsl:comment>
      <xsl:text>XSLT Processor: </xsl:text>
      <xsl:value-of select="system-property('xsl:vendor')"/>
      <xsl:if test="system-property('xsl:version') = '2.0'">
        <xsl:value-of select="system-property('xsl:product-name')"/>
        <xsl:value-of select="system-property('xsl:product-version')"/>
      </xsl:if>
    </xsl:comment>
    <!-- end of proposed new code -->
    <xsl:if test="//prod[@num] and //prod[not(@num)]">
   <!-- dot dot dot -->
 


LightInTheBox - Buy quality products at wholesale price!