Mini Shell
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:fo="http://www.w3.org/1999/XSL/Format">
<xsl:output method="xml" indent="no"/>
<xsl:strip-space elements="*"/>
<xsl:template match="*">
<xsl:choose>
<xsl:when test="SMStatus='0'"><xsl:call-template name="success"/></xsl:when>
<xsl:otherwise>
<xsl:call-template name="failure">
<xsl:with-param name="ErrorMsgID"><xsl:value-of select="SMStatus"/></xsl:with-param>
</xsl:call-template>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<xsl:template name="failure">
<xsl:param name="ErrorMsgID" />
<DataArea>
<xsl:choose>
<xsl:when test="$ErrorMsgID='261'"><xsl:text>Error! Configuration file is missing.</xsl:text></xsl:when>
<xsl:when test="$ErrorMsgID='263'"><xsl:text>Error! Configuration key is missing.</xsl:text></xsl:when>
<xsl:when test="$ErrorMsgID='271'"><xsl:text>Error! Value incorrect.</xsl:text></xsl:when>
<xsl:when test="$ErrorMsgID='1376'"><xsl:text>Error! Webserver not present get and set operations not supported.</xsl:text></xsl:when>
<xsl:otherwise><xsl:text>Error occured!</xsl:text></xsl:otherwise>
</xsl:choose>
</DataArea>
</xsl:template>
<xsl:template name="success">
<DataArea>
<ListData>
<xsl:choose>
<xsl:when test="keysignalgorithm">
<Data>
<xsl:attribute name="display">Key signing algorithm</xsl:attribute>
<xsl:attribute name="value"><xsl:value-of select="keysignalgorithm"/></xsl:attribute>
</Data>
</xsl:when>
<xsl:otherwise>
<Data>
<xsl:choose>
<xsl:when test="AddressList">
<xsl:choose>
<xsl:when test="AddressList/URL='null'">
<xsl:attribute name="display">Webserver URL</xsl:attribute>
<xsl:attribute name="value">Not Configured</xsl:attribute>
</xsl:when>
<xsl:otherwise>
<xsl:attribute name="display">Webserver URL</xsl:attribute>
<xsl:attribute name="value"><xsl:value-of select="AddressList/ProductLaunchPoint"/> </xsl:attribute>
</xsl:otherwise>
</xsl:choose>
</xsl:when>
<xsl:when test="ciphers">
<xsl:attribute name="display">CIPHERS-Value</xsl:attribute>
<xsl:attribute name="value"><xsl:value-of select="ciphers"/></xsl:attribute>
</xsl:when>
<xsl:when test="sslprotocol">
<xsl:attribute name="display">SSLProtocolValue</xsl:attribute>
<xsl:attribute name="value"><xsl:value-of select="sslprotocol"/></xsl:attribute>
</xsl:when>
<xsl:when test="port">
<xsl:attribute name="display">PortValue</xsl:attribute>
<xsl:attribute name="value"><xsl:value-of select="port"/></xsl:attribute>
</xsl:when>
<xsl:when test="sessiontimeout">
<xsl:attribute name="display">SessionTimeout Value</xsl:attribute>
<xsl:attribute name="value"><xsl:value-of select="sessiontimeout"/></xsl:attribute>
</xsl:when>
<xsl:when test="address=''">
<xsl:attribute name="display">IPAddress</xsl:attribute>
<xsl:attribute name="value">Not Configured</xsl:attribute>
</xsl:when>
<xsl:otherwise>
<xsl:attribute name="display">IPAddress</xsl:attribute>
<xsl:attribute name="value"><xsl:value-of select="address"/></xsl:attribute>
</xsl:otherwise>
</xsl:choose>
</Data>
</xsl:otherwise>
</xsl:choose>
</ListData>
</DataArea>
</xsl:template>
</xsl:stylesheet>
Zerion Mini Shell 1.0