<?xml version="1.0" encoding="ISO-8859-1"?>

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:output method="html"/>

<xsl:template match="/REPOSITORYSUMMARY">
    <html> <head> <title> <xsl:text>Paul's ActiveState Repo</xsl:text> </title> </head>

    <img align="left" style="margin: 0.25em; margin-right: 1em;" src="/pics/v.logo.png"/>
    <h1><xsl:text>Paul's </xsl:text> <xsl:value-of select="@ARCHITECTURE"/><xsl:text> ActiveState Repo</xsl:text></h1>

    <br clear="all"/>
    <p>
        <ul style="width: 6in">
            <xsl:apply-templates mode="modules"/>
        </ul>
    </p>
    </html>
</xsl:template>

<xsl:template match="SOFTPKG" mode="modules">
    <li>
        <a>
            <xsl:attribute name="href">
                <xsl:value-of select="CODEBASE/@HREF"/>
            </xsl:attribute>
            <xsl:value-of select="@NAME"/> <xsl:text> - v</xsl:text><xsl:value-of select="@VERSION"/>
        </a>

        <xsl:if test="IMPLEMENTATION/DEPENDENCY">
            <xsl:text> &#8212; Requires:</xsl:text>
            <ul>
            <xsl:for-each select="IMPLEMENTATION/DEPENDENCY">
                <li> <xsl:value-of select="@NAME"/> <xsl:text> - v</xsl:text><xsl:value-of select="@VERSION"/> </li>
            </xsl:for-each>
            </ul>
        </xsl:if>

    </li>
</xsl:template>

</xsl:stylesheet>

