sitemap.xsl revision 66e48875fca2df6669dab4f2690ee36c6913c0ff
beaad6ac31022179c44d88536811e9ccd9425696nd<?xml version="1.0"?>
beaad6ac31022179c44d88536811e9ccd9425696nd
beaad6ac31022179c44d88536811e9ccd9425696nd<!--
6fbd2e53c97ea6976d93e0ac521adabc55e0fb73nd Copyright 2002-2004 The Apache Software Foundation
beaad6ac31022179c44d88536811e9ccd9425696nd
beaad6ac31022179c44d88536811e9ccd9425696nd Licensed under the Apache License, Version 2.0 (the "License");
beaad6ac31022179c44d88536811e9ccd9425696nd you may not use this file except in compliance with the License.
beaad6ac31022179c44d88536811e9ccd9425696nd You may obtain a copy of the License at
beaad6ac31022179c44d88536811e9ccd9425696nd
beaad6ac31022179c44d88536811e9ccd9425696nd http://www.apache.org/licenses/LICENSE-2.0
beaad6ac31022179c44d88536811e9ccd9425696nd
beaad6ac31022179c44d88536811e9ccd9425696nd Unless required by applicable law or agreed to in writing, software
beaad6ac31022179c44d88536811e9ccd9425696nd distributed under the License is distributed on an "AS IS" BASIS,
beaad6ac31022179c44d88536811e9ccd9425696nd WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
beaad6ac31022179c44d88536811e9ccd9425696nd See the License for the specific language governing permissions and
beaad6ac31022179c44d88536811e9ccd9425696nd limitations under the License.
beaad6ac31022179c44d88536811e9ccd9425696nd-->
beaad6ac31022179c44d88536811e9ccd9425696nd
01c674544bd4c211141bcd9fb09b96ffc18c6c3dnd<!DOCTYPE xsl:stylesheet [
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <!ENTITY lf SYSTEM "util/lf.xml">
01c674544bd4c211141bcd9fb09b96ffc18c6c3dnd]>
9a658bb3989694b409e700f2842c892224fc9700nd<xsl:stylesheet version="1.0"
9a658bb3989694b409e700f2842c892224fc9700nd xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
9a658bb3989694b409e700f2842c892224fc9700nd xmlns="http://www.w3.org/1999/xhtml">
9a658bb3989694b409e700f2842c892224fc9700nd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- If we use document() in the context of this xsl file, the contextual -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- CWD is the xsl file containing directory. $basedir reflects the -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- manual root for that case. -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:variable name="basedir" select="'../../'" />
9a658bb3989694b409e700f2842c892224fc9700nd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- <sitemap> -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- Process an entire document into an HTML page -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:template match="/sitemap">
66e48875fca2df6669dab4f2690ee36c6913c0ffnd<html xml:lang="{$doclang}" lang="{$doclang}">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:call-template name="head" />&lf;
9a658bb3989694b409e700f2842c892224fc9700nd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <body id="manual-page">&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:call-template name="top" />&lf;
d3cd98e7839dd1c737c18d42a916ed20860a50e1nd
9a658bb3989694b409e700f2842c892224fc9700nd <div id="page-content">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <div id="preamble">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <h1>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:value-of select="title" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </h1>&lf;
9a658bb3989694b409e700f2842c892224fc9700nd
8cfbcde8e416fd60132dd4324c42a5098da156cfnd <xsl:call-template name="langavail" />&lf;
8cfbcde8e416fd60132dd4324c42a5098da156cfnd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:apply-templates select="summary" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </div>&lf; <!-- /#preamble -->
9a658bb3989694b409e700f2842c892224fc9700nd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:if test="(not($is-chm) and count(category) &gt; 1) or seealso">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <div id="quickview">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:if test="not($is-chm) and count(category) &gt; 1">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <ul id="toc">&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:for-each select="category">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:choose>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:when test="@id">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <li>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <img src="{$path}/images/down.gif" alt="" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:text> </xsl:text>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <a href="#{@id}">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:apply-templates
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="title" mode="print" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </a>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </li>&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:when>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:otherwise>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <li>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <img src="{$path}/images/down.gif" alt="" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:text> </xsl:text>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:apply-templates
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="title" mode="print" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </li>&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:otherwise>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:choose>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:for-each>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </ul>&lf;
9a658bb3989694b409e700f2842c892224fc9700nd </xsl:if>
9a658bb3989694b409e700f2842c892224fc9700nd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:if test="seealso">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <h3>
66e48875fca2df6669dab4f2690ee36c6913c0ffnd <xsl:value-of select="$message
66e48875fca2df6669dab4f2690ee36c6913c0ffnd [@id='seealso']" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </h3>&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <ul class="seealso">&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:for-each select="seealso">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <li>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:apply-templates />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </li>&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:for-each>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </ul>&lf;
9a658bb3989694b409e700f2842c892224fc9700nd </xsl:if>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </div>&lf; <!-- /#quickview -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:if> <!-- have sidebar -->
d3cd98e7839dd1c737c18d42a916ed20860a50e1nd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:apply-templates select="category" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </div>&lf; <!-- /#page-content -->
d3cd98e7839dd1c737c18d42a916ed20860a50e1nd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:call-template name="bottom" />&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </body>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</html>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:template>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- /sitemap -->
9a658bb3989694b409e700f2842c892224fc9700nd
9a658bb3989694b409e700f2842c892224fc9700nd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- category/page -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:template match="sitemap/category/page">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<li>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:if test="@separate='yes'">
480bee29abcc415b6b8c18d2ecbf2c5f88f1f05bnd <xsl:attribute name="class">separate</xsl:attribute>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:if>
480bee29abcc415b6b8c18d2ecbf2c5f88f1f05bnd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:choose>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:when test="@href">
9a658bb3989694b409e700f2842c892224fc9700nd <a href="{@href}">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:call-template name="helper.uri.fix">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:with-param name="uri" select="@href" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:call-template>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:value-of select="." />
9a658bb3989694b409e700f2842c892224fc9700nd </a>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:when>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:otherwise>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:value-of select="." />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:otherwise>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:choose>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</li>&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:template>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- /category/page -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- Process a sitemap category -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:template match="sitemap/category">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:call-template name="toplink" />&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<div class="section">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <!-- Category title -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <h2>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:choose>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:when test="@id">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <a id="{@id}" name="{@id}">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:apply-templates select="title" mode="print" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </a>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:when>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:otherwise>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:apply-templates select="title" mode="print" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:otherwise>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:choose>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </h2>&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <!-- category body -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <ul>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:apply-templates select="page" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </ul>
9a658bb3989694b409e700f2842c892224fc9700nd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <!-- optional ... -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:apply-templates select="modulefilelist" />&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</div> <!-- /.section -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:template>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- /category -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- category/modulefilelist -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- insert module list into sitemap -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:template match="sitemap/category/modulefilelist">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:variable name="translist">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:text>-</xsl:text>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:for-each select="modulefile">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:variable name="current"
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="document(concat($basedir,'mod/',.))/modulesynopsis" />
4489f0b54d190e8ac29906e1071bbad6c49de17end
4489f0b54d190e8ac29906e1071bbad6c49de17end <xsl:text> </xsl:text>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:value-of select="$current/name" />
4489f0b54d190e8ac29906e1071bbad6c49de17end <xsl:text> </xsl:text>
4489f0b54d190e8ac29906e1071bbad6c49de17end <xsl:call-template name="module-translatename">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:with-param name="name" select="$current/name" />
4489f0b54d190e8ac29906e1071bbad6c49de17end </xsl:call-template>
4489f0b54d190e8ac29906e1071bbad6c49de17end <xsl:text> -</xsl:text>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:for-each>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:variable>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<ul>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<li>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <a href="mod/core.html">
66e48875fca2df6669dab4f2690ee36c6913c0ffnd <xsl:value-of select="$message[@id='apachecore']" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </a>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</li>&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<li>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <a href="mod/mpm_common.html">
66e48875fca2df6669dab4f2690ee36c6913c0ffnd <xsl:value-of select="$message[@id='apachempmcommon']" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </a>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</li>&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:for-each select="modulefile">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:sort select="substring-before(substring-after($translist, concat('- ',
7e68fce3cbd2246164e045a51ecd77f9f26680ednd document(concat($basedir,'mod/',.))/modulesynopsis/name, ' ')), ' -')" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:variable name="current" select="document(concat($basedir, 'mod/', .))
7e68fce3cbd2246164e045a51ecd77f9f26680ednd /modulesynopsis" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:if test="$current/status='MPM' and $current/name!='mpm_common'">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:variable name="name" select="substring-before(substring-after(
7e68fce3cbd2246164e045a51ecd77f9f26680ednd $translist, concat('- ', $current/name, ' ')), ' -')" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <li>
9a658bb3989694b409e700f2842c892224fc9700nd <a href="mod/{$current/name}.html">
66e48875fca2df6669dab4f2690ee36c6913c0ffnd <xsl:value-of select="$message[@id='apachempm']" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:text> </xsl:text>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:value-of select="$name" />
9a658bb3989694b409e700f2842c892224fc9700nd </a>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </li>&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:if>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:for-each>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</ul>
8a72c24379e10c3f3d0dfe352bf15e45ee65c179nd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<ul>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:for-each select="modulefile">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:sort select="substring-before(substring-after($translist, concat('- ',
7e68fce3cbd2246164e045a51ecd77f9f26680ednd document(concat($basedir,'mod/',.))/modulesynopsis/name, ' ')), ' -')"/>
8a72c24379e10c3f3d0dfe352bf15e45ee65c179nd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:variable name="current" select="document(concat($basedir,'mod/',.))
7e68fce3cbd2246164e045a51ecd77f9f26680ednd /modulesynopsis" />
3c56725151a46fef84ce376d709b5339da28e10fnd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:if test="$current/status!='MPM' and $current/status!='Core'">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <li>
4489f0b54d190e8ac29906e1071bbad6c49de17end <a href="mod/{$current/name}.html">
66e48875fca2df6669dab4f2690ee36c6913c0ffnd <xsl:value-of select="$message[@id='apachemodule']"/>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:text> </xsl:text>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:value-of select="$current/name"/>
3c56725151a46fef84ce376d709b5339da28e10fnd </a>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </li>&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:if>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:for-each>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</ul>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:template>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- /category/modulefilelist -->
9a658bb3989694b409e700f2842c892224fc9700nd
9a658bb3989694b409e700f2842c892224fc9700nd</xsl:stylesheet>