<?xml version="1.0" encoding="Shift_JIS"?>
<xsl:stylesheet
 xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
 xmlns="http://www.w3.org/1999/xhtml"
 version="1.0"
 exclude-result-prefixes="#default">

 <xsl:output method="html" encoding="EUC_JP"
  doctype-public="-//W3C//DTD HTML 4.0//EN"
  doctype-system="http://www.w3.org/TR/html4/strict.dtd"
  indent="yes"/>

<!--
-->

 <xsl:template match="link-list">
  <html lang="ja">
  <head>
  <meta http-equiv="CONTENT-STYLE-TYPE" content="text/css"/>
  <link rel="CONTENTS" href="./"/>
  <link rev="MADE" href="mailto:morris@musical-fan.org"/>
  <link rel="stylesheet" type="text/css" href="./musical.css"/>
  <title>ミュージカル関連リンク集</title>
  </head>
  <body>
  <p><a accesskey="H" href="./">[ミュージカル・ホームへ]</a></p>
  <hr/>
  <h1>ミュージカル関連リンク集</h1>
  <ul>
   <xsl:apply-templates select="category" mode="list"/>
  </ul>

  <hr/>
  <xsl:apply-templates select="category" mode="contents"/>

  <hr/>
  <p>劇団は主な活動拠点で分類しました。順番は50音順です。<br/>
  ここに載っていないミュージカル劇団のページをご存知の方、
  メールください。</p>
  </body>
  </html>
 </xsl:template>

 <xsl:template match="category" mode="list">
  <li><a href="#{@id}"><xsl:value-of select="@jenre"/></a></li>
 </xsl:template>

 <xsl:template match="category" mode="contents">
  <xsl:variable name="cname"><xsl:value-of select="@id"/></xsl:variable>
  <h2 class="title"><a name="{@id}"><xsl:value-of select="@jenre"/></a></h2>
  <dl>
   <xsl:for-each select="/link-list/link">
    <xsl:sort select="name/@yomi"/>
     <xsl:if test="jenre=$cname">
      <xsl:apply-templates select="."/>
     </xsl:if>
   </xsl:for-each>
  </dl>
 </xsl:template>

 <xsl:template match="link">
  <dt><a><xsl:attribute name="href">
   <xsl:value-of select="url"/></xsl:attribute>
   <xsl:value-of select="name"/></a></dt>
  <dd><xsl:value-of select="note"/></dd>
 </xsl:template>

</xsl:stylesheet>

