Add media title to directory header

foo
David Bartley 16 years ago
parent 2f8c419206
commit 9f59677f5a
  1. 14
      xsl/common.xsl
  2. 15
      xsl/directory.xsl
  3. 5
      xsl/media.xsl

@ -53,7 +53,13 @@
</div>
</xsl:template>
<xsl:template match="header" name="header">
<xsl:template match="header">
<xsl:call-template name="header" />
</xsl:template>
<xsl:template name="header">
<xsl:param name="title" />
<xsl:param name="href" />
<div id="vfeed" />
<div class="webtitle">
<div class="csclogo">
@ -68,6 +74,12 @@
<div class="template-header">
<xsl:apply-templates
select="document(concat($g_pwd, '/directory.xml'))/directory"/>
<xsl:if test="$title">
<xsl:call-template name="diritem">
<xsl:with-param name="title" select="$title" />
<xsl:with-param name="href" select="$href" />
</xsl:call-template>
</xsl:if>
</div>
</xsl:template>

@ -23,10 +23,19 @@
<xsl:apply-templates select="diritem" />
</xsl:template>
<xsl:template match="diritem">
<a class="diritem" href="{@href}">
<xsl:value-of select="@title" />
<xsl:template name="diritem">
<xsl:param name="title" />
<xsl:param name="href" />
<a class="diritem" href="{$href}">
<xsl:value-of select="$title" />
</a>
</xsl:template>
<xsl:template match="diritem">
<xsl:call-template name="diritem">
<xsl:with-param name="title" select="@title" />
<xsl:with-param name="href" select="@href" />
</xsl:call-template>
</xsl:template>
</xsl:stylesheet>

@ -65,7 +65,10 @@
<link rel="stylesheet" href="{$pre}default.css" type="text/css" />
</head>
<body><div>
<xsl:call-template name="header" />
<xsl:call-template name="header">
<xsl:with-param name="title" select="@title" />
<xsl:with-param name="href" select="concat(@title, $suffix, '.html')" />
</xsl:call-template>
<xsl:if test="abstract">
<h2>Abstract</h2>
<div>

Loading…
Cancel
Save