common.xsl revision 7e68fce3cbd2246164e045a51ecd77f9f26680ed
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<?xml version="1.0"?><!--
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen/* ====================================================================
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * The Apache Software License, Version 1.1
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen *
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * Copyright (c) 2002-2003 The Apache Software Foundation. All rights
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * reserved.
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen *
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * Redistribution and use in source and binary forms, with or without
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * modification, are permitted provided that the following conditions
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * are met:
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen *
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * 1. Redistributions of source code must retain the above copyright
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * notice, this list of conditions and the following disclaimer.
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen *
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * 2. Redistributions in binary form must reproduce the above copyright
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * notice, this list of conditions and the following disclaimer in
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * the documentation and/or other materials provided with the
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * distribution.
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen *
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * 3. The end-user documentation included with the redistribution,
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * if any, must include the following acknowledgment:
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * "This product includes software developed by the
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * Apache Software Foundation (http://www.apache.org/)."
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * Alternately, this acknowledgment may appear in the software itself,
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * if and wherever such third-party acknowledgments normally appear.
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen *
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * 4. The names "Apache" and "Apache Software Foundation" must
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * not be used to endorse or promote products derived from this
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * software without prior written permission. For written
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * permission, please contact apache@apache.org.
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen *
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * 5. Products derived from this software may not be called "Apache",
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * nor may "Apache" appear in their name, without prior written
8b197c3a8a57c3f7c231b39e5660856fd9580c80Auke Kok * permission of the Apache Software Foundation.
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen *
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho * SUCH DAMAGE.
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho * ====================================================================
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho *
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho * This software consists of voluntary contributions made by many
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho * individuals on behalf of the Apache Software Foundation. For more
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho * information on the Apache Software Foundation, please see
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho * <http://www.apache.org/>.
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho */ -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<!DOCTYPE xsl:stylesheet [
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek <!ENTITY nbsp SYSTEM "util/nbsp.xml">
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <!ENTITY lf SYSTEM "util/lf.xml">
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek]>
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<xsl:stylesheet version="1.0"
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho xmlns="http://www.w3.org/1999/xhtml">
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<!-- -->
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek<!-- Please, don't hard-code output strings! Use the language -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<!-- files and the translation "stuff"... -->
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek<!-- -->
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<!-- Injected variables: -->
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<!-- $is-chm - (boolean) target is for CHM generation or not -->
fea7838e7e0b2724f5e0bc028121a08b42995045Zbigniew Jędrzejewski-Szmek<!-- $messages - (node-set) localized common text snippets -->
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<!-- $output-encoding - (string) MIME charset name of the output -->
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<!-- encoding -->
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<!-- Constants used for case translation -->
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<xsl:variable name="lowercase" select="'abcdefghijklmnopqrstuvwxyz'" />
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<xsl:variable name="uppercase" select="'ABCDEFGHIJKLMNOPQRSTUVWXYZ'" />
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<!-- space separated list of blockelements defined in common.dtd -->
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek<!-- used for inline content catching in <example>s -->
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek<xsl:variable name="blockelements">
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek p example note table ul ol dl pre img blockquote
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek</xsl:variable>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<!-- relative path to /manual/ -->
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<xsl:variable name="path" select="document(/*/@metafile)/metafile/relpath" />
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek<!-- load outsourced page types -->
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<xsl:include href="moduleindex.xsl" />
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek<xsl:include href="directiveindex.xsl" />
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek<xsl:include href="manualpage.xsl" />
03e334a1c7dc8c20c38902aa039440763acc9b17Lennart Poettering<xsl:include href="synopsis.xsl" />
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<xsl:include href="sitemap.xsl" />
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<xsl:include href="indexpage.xsl" />
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<xsl:include href="quickreference.xsl" />
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<xsl:include href="faq.xsl" />
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen
fea7838e7e0b2724f5e0bc028121a08b42995045Zbigniew Jędrzejewski-Szmek<!-- load utility snippets -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<xsl:include href="util/modtrans.xsl" />
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<!-- make sure, we set relative anchors only, if we're actually -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<!-- transforming a modulefile (see <directive> template) -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<xsl:variable name="in-modulesynopsis" select="boolean(/modulesynopsis)" />
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<!-- when referencing to a directory, we may need to complete the path -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<!-- with the index file (for offline applications like *.chm files) -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<xsl:variable name="index-file">
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:if test="$is-chm">index.html</xsl:if>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho</xsl:variable>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<!-- it may be desired to open external targets in a new window -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<xsl:variable name="ext-target" select="boolean($is-chm)" />
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<!-- #################################################################### -->
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek<!-- Utility templates for constructing pages -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<!-- #################################################################### -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<!-- ==================================================================== -->
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek<!-- HTML head -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<!-- ==================================================================== -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<xsl:template name="head">
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<head>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <!-- the meta element is necessary for offline handling like CHM -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:choose>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:when test="$is-chm">
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <meta http-equiv="Content-Type"
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho content="text/html; charset={$output-encoding}" />
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho </xsl:when>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:otherwise>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:comment>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho &lf;
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:text> </xsl:text>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:text>XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</xsl:text>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho &lf;
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:text> </xsl:text>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:text>This file is generated from xml source: DO NOT EDIT</xsl:text>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho &lf;
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:text> </xsl:text>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:text>XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX</xsl:text>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho &lf;
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:text> </xsl:text>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho </xsl:comment>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho </xsl:otherwise>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho </xsl:choose>&lf;
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <title>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:choose>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:when test="name">
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:value-of select="name"/>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho </xsl:when>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:otherwise>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:value-of select="title"/>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho </xsl:otherwise>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho </xsl:choose>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:text> </xsl:text>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:value-of select="$messages/message[@name='apachetitle']"/>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho </title>&lf;
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <!-- chm files get a slightly different stylesheet -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:choose>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:when test="$is-chm">
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <link type="text/css" rel="stylesheet" media="all"
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho href="{$path}/style/css/manual-chm.css" />
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho </xsl:when>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:otherwise>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <link title="Main stylesheet" type="text/css" media="all"
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho rel="stylesheet"
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho href="{$path}/style/css/manual.css" />&lf;
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <link title="No Sidebar - Default font size" type="text/css" media="all"
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho rel="alternate stylesheet"
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho href="{$path}/style/css/manual-loose-100pc.css"/>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho </xsl:otherwise>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho </xsl:choose>&lf;
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <link type="text/css" media="print"
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho rel="stylesheet"
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho href="{$path}/style/css/manual-print.css"/>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <!-- chm files do not need a favicon -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:if test="not($is-chm)">&lf;
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <link rel="shortcut icon" href="{$path}/images/favicon.ico" />
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho </xsl:if>
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek</head>
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek</xsl:template>
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<!-- /head -->
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek<!-- ==================================================================== -->
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<!-- page top -->
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<!-- ==================================================================== -->
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen<xsl:template name="top">
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho<div id="page-header">&lf;
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek <xsl:call-template name="super-menu" />&lf;
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski <p class="apache">
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen <xsl:value-of select="$messages/message[@name='apachehttpserver']"/>
8a188de9e0ea41509beda12084126d7a75ebe86eWaLyong Cho </p>&lf;
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski <img src="{$path}/images/feather.gif" alt="" />
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski</div>&lf; <!-- /page-header -->
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek<div class="up">
e49d3c016751c03e544697656e8e596af8a664d7Łukasz Stelmach <a href="./{$index-file}">
e49d3c016751c03e544697656e8e596af8a664d7Łukasz Stelmach <xsl:if test="parentdocument">
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:attribute name="href">
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek <xsl:value-of select="parentdocument/@href"/>
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek </xsl:attribute>
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek <xsl:call-template name="helper.uri.fix">
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek <xsl:with-param name="uri" select="parentdocument/@href" />
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho </xsl:call-template>
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek </xsl:if>
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek <img src="{$path}/images/left.gif" alt="&lt;-" title="&lt;-" />
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen </a>
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen</div>&lf;
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen<div id="path">&lf;
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen <a href="http://www.apache.org/">
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen <xsl:if test="$ext-target">
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen <xsl:attribute name="target">_blank</xsl:attribute>
8b197c3a8a57c3f7c231b39e5660856fd9580c80Auke Kok </xsl:if>
4c1fc3e404d648c70bd2f50ac50aeac6ece8872eDaniel Mack <xsl:value-of select="$messages/message[@name='apache']" />
8b197c3a8a57c3f7c231b39e5660856fd9580c80Auke Kok </a>
8b197c3a8a57c3f7c231b39e5660856fd9580c80Auke Kok
8b197c3a8a57c3f7c231b39e5660856fd9580c80Auke Kok <xsl:text> &gt; </xsl:text>
8b197c3a8a57c3f7c231b39e5660856fd9580c80Auke Kok
8b197c3a8a57c3f7c231b39e5660856fd9580c80Auke Kok <a href="http://httpd.apache.org/">
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:if test="$ext-target">
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen <xsl:attribute name="target">_blank</xsl:attribute>
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen </xsl:if>
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen <xsl:value-of select="$messages/message[@name='http-server']" />
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen </a>
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen
6656aefb42385b468dd96867118d049f945cbf81WaLyong Cho <xsl:text> &gt; </xsl:text>
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen <a href="http://httpd.apache.org/docs-project/">
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen <xsl:if test="$ext-target">
b9289d4c6e13ec5fb67bfce69c826d93b004da6aPhilippe De Swert <xsl:attribute name="target">_blank</xsl:attribute>
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek </xsl:if>
abbacb1defaaecb8d2477685f7bb3fabcf58585bNathaniel Chen <xsl:value-of select="$messages/message[@name='documentation']" />
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek </a>
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek
a4783bd17ad96f55b0fe83a50959da13555292bfZbigniew Jędrzejewski-Szmek <xsl:if test="not(/indexpage)">
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski <xsl:text> &gt; </xsl:text>
e49d3c016751c03e544697656e8e596af8a664d7Łukasz Stelmach
e49d3c016751c03e544697656e8e596af8a664d7Łukasz Stelmach <a href="{$path}/{$index-file}">
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski <xsl:value-of select="$messages/message[@name='version']"/>
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski </a>
2b3e18de74ca89b374dd4f7a2c30e5731d347841Karol Lewandowski </xsl:if>
ffbd2c4d45787ba5ba85a32db6551efba66a1ee6Nathaniel Chen
<xsl:if test="/modulesynopsis or /directiveindex or /quickreference">
<xsl:text> &gt; </xsl:text>
<a href="./{$index-file}">
<xsl:value-of select="$messages/message[@name='modules']"/>
</a>
</xsl:if>
<xsl:if test="parentdocument/text()">
<xsl:text> &gt; </xsl:text>
<a href="{parentdocument/@href}">
<xsl:call-template name="helper.uri.fix">
<xsl:with-param name="uri" select="parentdocument/@href"/>
</xsl:call-template>
<xsl:value-of select="parentdocument"/>
</a>
</xsl:if>
</div> <!-- /path -->
</xsl:template>
<!-- /top -->
<!-- ==================================================================== -->
<!-- page bottom -->
<!-- ==================================================================== -->
<xsl:template name="bottom">
<div id="footer">&lf;
<p class="apache">
<xsl:value-of select="$messages/message[@name='maintainedby']"/>
<xsl:text> </xsl:text>
<a href="http://httpd.apache.org/docs-project/">
<xsl:if test="$ext-target">
<xsl:attribute name="target">_blank</xsl:attribute>
</xsl:if>
<xsl:text>Apache HTTP Server Documentation Project</xsl:text>
</a>
</p>&lf;
<xsl:call-template name="super-menu"/>
</div> <!-- /footer -->
</xsl:template>
<!-- /bottom -->
<!-- ==================================================================== -->
<!-- Process a documentation section -->
<!-- ==================================================================== -->
<xsl:template match="section">
<xsl:call-template name="toplink" />&lf;
<div class="section">&lf;
<!-- Section heading -->
<h2>
<xsl:choose>
<xsl:when test="@id">
<a id="{@id}" name="{@id}">
<xsl:apply-templates select="title" mode="print" />
</a>
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates select="title" mode="print" />
</xsl:otherwise>
</xsl:choose>
</h2>
<!-- Section body -->
<xsl:apply-templates />
</div> <!-- /.section -->
</xsl:template>
<!-- /section -->
<!-- ==================================================================== -->
<!-- handle subsections (lower level headings) -->
<!-- ==================================================================== -->
<xsl:template match="section/section">
<!-- Section heading -->
<h3>
<xsl:choose>
<xsl:when test="@id">
<a id="{@id}" name="{@id}">
<xsl:apply-templates select="title" mode="print" />
</a>
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates select="title" mode="print" />
</xsl:otherwise>
</xsl:choose>
</h3>
<!-- Section body -->
<xsl:apply-templates />
</xsl:template>
<!-- /section/section -->
<!-- ==================================================================== -->
<!-- handle subsubsections (h4) -->
<!-- ==================================================================== -->
<xsl:template match="section/section/section">
<!-- Section heading -->
<h4>
<xsl:choose>
<xsl:when test="@id">
<a id="{@id}" name="{@id}">
<xsl:apply-templates select="title" mode="print" />
</a>
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates select="title" mode="print" />
</xsl:otherwise>
</xsl:choose>
</h4>
<!-- Section body -->
<xsl:apply-templates/>
</xsl:template>
<!-- /section/section/section -->
<!-- ==================================================================== -->
<!-- section nesting > h4 is not supported for now -->
<!-- ==================================================================== -->
<xsl:template match="section/section/section/section">
<xsl:message terminate="yes">
<xsl:text>FATAL: exceeding maximum section nesting level.</xsl:text>
&lf;&lf;
<xsl:text>Perhaps you should consider to split your document into</xsl:text>
&lf;
<xsl:text>several ones...</xsl:text>
&lf;
</xsl:message>
</xsl:template>
<!-- /section/section/section/section -->
<!-- ==================================================================== -->
<!-- (sub)section titles -->
<!-- ==================================================================== -->
<xsl:template match="section/title" mode="print">
<xsl:apply-templates/>
</xsl:template>
<xsl:template match="section/title" />
<!-- /section/title -->
<!-- ==================================================================== -->
<!-- generate section index -->
<!-- ==================================================================== -->
<xsl:template match="section" mode="index">
<li>
<img src="{$path}/images/down.gif" alt="" />
<xsl:text> </xsl:text>
<xsl:choose>
<xsl:when test="@id">
<a href="#{@id}">
<xsl:apply-templates select="title" mode="print" />
</a>
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates select="title" mode="print" />
</xsl:otherwise>
</xsl:choose>
</li>&lf;
</xsl:template>
<!-- /section index -->
<!-- ==================================================================== -->
<!-- docs super menu -->
<!-- ==================================================================== -->
<xsl:template name="super-menu">
<p class="menu">
<a href="{$path}/mod/{$index-file}">
<xsl:value-of select="$messages/message[@name='modules']" />
</a>
<xsl:text> | </xsl:text>
<a href="{$path}/mod/directives.html">
<xsl:value-of select="$messages/message[@name='directives']" />
</a>
<xsl:text> | </xsl:text>
<a href="{$path}/faq/{$index-file}">
<xsl:value-of select="$messages/message[@name='faq']" />
</a>
<xsl:text> | </xsl:text>
<a href="{$path}/glossary.html">
<xsl:value-of select="$messages/message[@name='glossary']" />
</a>
<xsl:text> | </xsl:text>
<a href="{$path}/sitemap.html">
<xsl:value-of select="$messages/message[@name='sitemap']" />
</a>
</p>
</xsl:template>
<!-- /super-menu -->
<!-- ==================================================================== -->
<!-- <example> -->
<!-- iterate over *all* nodes; bare text and other inline stuff is -->
<!-- wrapped into <p><code>, block level elements (defined in -->
<!-- $blockelements) are applied "as is" -->
<!-- ==================================================================== -->
<xsl:variable name="blocks"
select="concat(' ', normalize-space($blockelements), ' ')" />
<xsl:template match="example">
<div class="example">
<xsl:apply-templates select="title" mode="print" />
<xsl:for-each select="/node()">
<xsl:variable name="is-block-node"
select="boolean(contains($blocks,
concat(' ', local-name(), ' ')))"/>
<!-- bb = (number of) blocks nodes before (the current) -->
<xsl:variable name="bb"
select="count(preceding-sibling::*[
contains($blocks,
concat(' ', local-name(), ' '))])" />
<xsl:if test="$is-block-node or position()=last()">
<xsl:variable name="content">
<!-- phew. short explanation, what happens here: -->
<!-- We want to get the inline stuff between the last -->
<!-- block node and the current node. -->
<!-- So filter all previous nodes for the condition -->
<!-- that the number of block nodes of all of *their* -->
<!-- previous nodes is >= $bb. Hope that helps ;-) -->
<xsl:apply-templates
select="preceding-sibling::node()[
count(preceding-sibling::*[
contains($blocks,
concat(' ', local-name(), ' '))])
&gt;= $bb]" />
<xsl:apply-templates
select="self::node()[not($is-block-node)]" />
</xsl:variable>
<!-- apply bare text only, if it's not only \s or empty -->
<xsl:if test="not(normalize-space($content) = '')">
<p><code>
<xsl:copy-of select="$content" />
</code></p>
</xsl:if>
<xsl:apply-templates select="self::node()[$is-block-node]" />
</xsl:if>
</xsl:for-each>
<!-- /node() -->
</div> <!-- /.example -->
</xsl:template>
<!-- /example -->
<!-- ==================================================================== -->
<!-- example/title -->
<!-- ==================================================================== -->
<xsl:template match="example/title" mode="print">
<h3>
<xsl:apply-templates/>
</h3>
</xsl:template>
<xsl:template match="example/title" />
<!-- /example/title -->
<!-- ==================================================================== -->
<!-- indentations -->
<!-- ==================================================================== -->
<xsl:template match="indent">
<span class="indent">
<xsl:apply-templates/>
</span>
</xsl:template>
<!-- /indent -->
<!-- ==================================================================== -->
<!-- <note> -->
<!-- ==================================================================== -->
<xsl:template match="note">
<div class="note">
<xsl:if test="@type='warning'">
<xsl:attribute name="class">warning</xsl:attribute>
</xsl:if>
<xsl:apply-templates/>
</div>
</xsl:template>
<!-- /note -->
<!-- ==================================================================== -->
<!-- <note><title> -->
<!-- ==================================================================== -->
<xsl:template match="note/title">
<h3>
<xsl:apply-templates/>
</h3>
</xsl:template>
<!-- /note/title -->
<!-- ==================================================================== -->
<!-- <directive> -->
<!-- Inserts link to another directive, which might be in another module. -->
<!-- References are converted into lower case. -->
<!-- ==================================================================== -->
<xsl:template match="directive" name="directive">
<code class="directive">
<xsl:choose>
<xsl:when test="@module">
<xsl:variable name="lowerdirective"
select="translate(., $uppercase, $lowercase)" />
<xsl:choose>
<xsl:when test="$in-modulesynopsis and @module = /modulesynopsis/name">
<a href="#{$lowerdirective}">
<xsl:if test="@type='section'">&lt;</xsl:if>
<xsl:value-of select="."/>
<xsl:if test="@type='section'">&gt;</xsl:if>
</a>
</xsl:when>
<xsl:otherwise>
<a href="{$path}/mod/{@module}.html#{$lowerdirective}">
<xsl:if test="@type='section'">&lt;</xsl:if>
<xsl:value-of select="."/>
<xsl:if test="@type='section'">&gt;</xsl:if>
</a>
</xsl:otherwise>
</xsl:choose>
</xsl:when>
<xsl:otherwise>
<xsl:if test="@type='section'">&lt;</xsl:if>
<xsl:value-of select="."/>
<xsl:if test="@type='section'">&gt;</xsl:if>
</xsl:otherwise>
</xsl:choose>
</code>
</xsl:template>
<!-- /directive -->
<!-- ==================================================================== -->
<!-- <module> -->
<!-- Inserts a link to refereed module -->
<!-- ==================================================================== -->
<xsl:template match="module" name="module">
<code class="module">
<a href="{$path}/mod/{.}.html">
<xsl:value-of select="."/>
</a>
</code>
</xsl:template>
<!-- /module -->
<!-- ==================================================================== -->
<!-- <related> -->
<!-- ==================================================================== -->
<xsl:template match="related">
<table class="related">
<tr>
<th>
<xsl:value-of select="$messages/message[@name='relatedmodules']" />
</th>
<th>
<xsl:value-of select="$messages/message[@name='relateddirectives']" />
</th>
</tr>
<tr>
<td>
<xsl:if test="count(modulelist/*) &gt; 0">
<ul>
<xsl:apply-templates select="modulelist" />
</ul>
</xsl:if>
</td>
<td>
<xsl:if test="count(directivelist/*) &gt; 0">
<ul>
<xsl:apply-templates select="directivelist"/>
</ul>
</xsl:if>
</td>
</tr>
</table>
</xsl:template>
<!-- /related -->
<!-- ==================================================================== -->
<!-- related/modulelist -->
<!-- ==================================================================== -->
<xsl:template match="related/modulelist">
<xsl:for-each select="module">
<li>
<xsl:call-template name="module"/>
</li>
</xsl:for-each>
</xsl:template>
<!-- /related/modulelist -->
<!-- ==================================================================== -->
<!-- related/directivelist -->
<!-- ==================================================================== -->
<xsl:template match="related/directivelist">
<xsl:for-each select="directive">
<li>
<xsl:call-template name="directive"/>
</li>
</xsl:for-each>
</xsl:template>
<!-- /related/directivelist -->
<!-- ==================================================================== -->
<!-- <table> -->
<!-- ==================================================================== -->
<xsl:template match="table">
<table>
<!-- existing border attribute will result in <table class="bordered"> -->
<xsl:if test="@border">
<xsl:attribute name="class">bordered</xsl:attribute>
</xsl:if>
<!-- style="zebra": alternating colors per row, i.e. every second row -->
<!-- gets a class="odd". Header lines (no <td>) get a -->
<!-- class="header". These lines will be excluded from -->
<!-- the "odd" line count. That way header lines act -->
<!-- interjectional, which creates a better visual and -->
<!-- psychological effect. -->
<xsl:choose>
<xsl:when test="@style = 'zebra'">
<xsl:for-each select="tr">
<tr>
<xsl:choose>
<xsl:when test="count(td) = 0">
<xsl:attribute name="class">header</xsl:attribute>
</xsl:when>
<xsl:when
test="position() mod 2 =
(count(preceding-sibling::*[count(td) = 0]) mod 2)">
<xsl:attribute name="class">odd</xsl:attribute>
</xsl:when>
</xsl:choose>
<xsl:apply-templates />
</tr>&lf;
</xsl:for-each>
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates />
</xsl:otherwise>
</xsl:choose>
</table>
</xsl:template>
<!-- /table -->
<!-- ==================================================================== -->
<!-- <ol> -->
<!-- ==================================================================== -->
<xsl:template match="ol">
<ol>
<!-- A. B. C. D. (list-style-type="upper-alpha") -->
<xsl:if test="@type = 'A'">
<xsl:attribute name="class">up-A</xsl:attribute>
</xsl:if>
<xsl:apply-templates/>
</ol>
</xsl:template>
<!-- /ol -->
<!-- ==================================================================== -->
<!-- diverse elements -->
<!-- Passes through content -->
<!-- ==================================================================== -->
<xsl:template match="summary|description|usage|syntax|default">
<xsl:apply-templates/>
</xsl:template>
<!-- /diverse -->
<!-- ==================================================================== -->
<!-- <a> -->
<!-- ==================================================================== -->
<xsl:template match="a">
<xsl:choose>
<xsl:when test="not(@href)">
<xsl:copy>
<xsl:apply-templates select="@*|*|text()"/>
</xsl:copy>
</xsl:when>
<xsl:otherwise>
<a href="@href">
<xsl:apply-templates select="@*"/>
<xsl:call-template name="helper.uri.fix">
<xsl:with-param name="uri" select="@href"/>
</xsl:call-template>
<xsl:apply-templates select="*|text()"/>
</a>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<!-- /a -->
<!-- ==================================================================== -->
<!-- toplink -->
<!-- ==================================================================== -->
<xsl:template name="toplink">
<div class="top">
<a href="#page-header"><img src="{$path}/images/up.gif" alt="top" /></a>
</div>
</xsl:template>
<!-- /toplink -->
<!-- ==================================================================== -->
<!-- <transnote> -->
<!-- translator's notes are displayed in a different color -->
<!-- ==================================================================== -->
<xsl:template match="transnote">
<span class="transnote">
<xsl:text>(</xsl:text>
<em>
<xsl:value-of select="$messages/message[@name='transnote']" />
</em>
<xsl:text> </xsl:text>
<xsl:apply-templates />
<xsl:text>)</xsl:text>
</span>
</xsl:template>
<!-- /transnote -->
<!-- ==================================================================== -->
<!-- Filter &#160; in text() nodes. -->
<!-- In some environments this character won't be transformed correctly, -->
<!-- so we just write it explicitely as "&nbsp;" into the output. -->
<!-- ==================================================================== -->
<xsl:template match="text()" name="filter.nbsp">
<xsl:param name="text" select="." />
<xsl:choose>
<xsl:when test="contains($text, '&#160;')">
<xsl:value-of select="substring-before($text, '&#160;')" />
&nbsp;
<xsl:call-template name="filter.nbsp">
<xsl:with-param name="text" select="substring-after($text, '&#160;')" />
</xsl:call-template>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="$text" />
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<!-- /filter.nbsp -->
<!-- ==================================================================== -->
<!-- Process everything else by just passing it through -->
<!-- ==================================================================== -->
<xsl:template match="*|@*">
<xsl:copy>
<xsl:apply-templates select="*|@*|text()" />
</xsl:copy>
</xsl:template>
<!-- /pass through -->
<!-- ==================================================================== -->
<!-- create a letter bar -->
<!-- ==================================================================== -->
<xsl:template name="letter-bar">
<xsl:param name="letters" />
<xsl:param name="first" />
<xsl:if test="not($first)">
<xsl:text> | </xsl:text>
</xsl:if>
<a href="#{substring($letters,1,1)}">
&nbsp;
<xsl:value-of select="substring($letters, 1, 1)" />
&nbsp;
</a>
<xsl:if test="string-length($letters) &gt; 1">
<xsl:call-template name="letter-bar">
<xsl:with-param name="letters" select="substring($letters, 2)" />
<xsl:with-param name="first" select="false()" />
</xsl:call-template>
</xsl:if>
</xsl:template>
<!-- /letter-bar -->
<!-- ==================================================================== -->
<!-- template(s) for collecting all start letters of directives -->
<!-- ==================================================================== -->
<xsl:template name="directive-startletters">
<xsl:param name="directives" />
<xsl:call-template name="_squeeze-letters">
<xsl:with-param name="lastletter" select="''" />
<xsl:with-param name="letters">
<xsl:for-each select="$directives">
<xsl:sort select="name"/>
<xsl:value-of
select="translate(substring(normalize-space(name), 1, 1),
$lowercase, $uppercase)" />
</xsl:for-each>
</xsl:with-param>
</xsl:call-template>
</xsl:template>
<!-- /directive-startletters -->
<!-- ==================================================================== -->
<!-- squeeze subsequent letters in a string -->
<!-- ==================================================================== -->
<xsl:template name="_squeeze-letters">
<xsl:param name="letters"/>
<xsl:param name="lastletter"/>
<xsl:variable name="current" select="substring($letters, 1, 1)" />
<xsl:if test="not($lastletter = $current)">
<xsl:value-of select="$current" />
</xsl:if>
<xsl:if test="string-length($letters) &gt; 1">
<xsl:call-template name="_squeeze-letters">
<xsl:with-param name="letters" select="substring($letters, 2)" />
<xsl:with-param name="lastletter" select="$current"/>
</xsl:call-template>
</xsl:if>
</xsl:template>
<!-- /_squeeze-letters -->
<!-- ==================================================================== -->
<!-- fix href and target attribute of an element. -->
<!-- ==================================================================== -->
<xsl:template name="helper.uri.fix">
<xsl:param name="uri"/>
<xsl:choose>
<!-- lame is_absolute_uri test -->
<xsl:when test=" contains($uri, ':')
and string-length(substring-before($uri, ':')) &lt; 7">
<xsl:if test="$ext-target">
<xsl:attribute name="target">_blank</xsl:attribute>
</xsl:if>
</xsl:when>
<xsl:otherwise>
<xsl:variable name="fragment">
<xsl:if test="contains($uri, '#')">
<xsl:value-of select="concat('#', substring-after($uri, '#'))"/>
</xsl:if>
</xsl:variable>
<xsl:variable name="absuri">
<xsl:choose>
<xsl:when test="contains($uri, '#')">
<xsl:value-of select="concat('#', substring-before($uri, '#'))"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="$uri"/>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:if test="substring($absuri, string-length($uri), 1) = '/'">
<xsl:attribute name="href">
<xsl:value-of select="concat($absuri, $index-file, $fragment)"/>
</xsl:attribute>
</xsl:if>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<!-- /helper.uri.fix -->
</xsl:stylesheet>