convmap.xsl revision d209ecb5fe6393098ebb1f1afeea3648b1bf89ea
beaad6ac31022179c44d88536811e9ccd9425696nd<?xml version="1.0"?>
beaad6ac31022179c44d88536811e9ccd9425696nd
beaad6ac31022179c44d88536811e9ccd9425696nd<!--
db878466c5e95073429dda0bdd001f45e9486e16fielding Licensed to the Apache Software Foundation (ASF) under one or more
db878466c5e95073429dda0bdd001f45e9486e16fielding contributor license agreements. See the NOTICE file distributed with
db878466c5e95073429dda0bdd001f45e9486e16fielding this work for additional information regarding copyright ownership.
db878466c5e95073429dda0bdd001f45e9486e16fielding The ASF licenses this file to You under the Apache License, Version 2.0
db878466c5e95073429dda0bdd001f45e9486e16fielding (the "License"); you may not use this file except in compliance with
db878466c5e95073429dda0bdd001f45e9486e16fielding the License. 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]>
3726777f47ac4bba3e21b075905959bbea47e72eerikabele<xsl:stylesheet version="1.0"
3726777f47ac4bba3e21b075905959bbea47e72eerikabele xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
3726777f47ac4bba3e21b075905959bbea47e72eerikabele xmlns="http://www.w3.org/1999/xhtml">
3726777f47ac4bba3e21b075905959bbea47e72eerikabele
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:output method="text" encoding="ISO-8859-1" indent="no" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- Constants used for case translation -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:variable name="lowercase" select="'abcdefghijklmnopqrstuvwxyz'" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:variable name="uppercase" select="'ABCDEFGHIJKLMNOPQRSTUVWXYZ'" />
66e48875fca2df6669dab4f2690ee36c6913c0ffnd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
3726777f47ac4bba3e21b075905959bbea47e72eerikabele<!-- <modulefilelist> -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- Builds the rewrite map -->
3726777f47ac4bba3e21b075905959bbea47e72eerikabele<!-- ==================================================================== -->
3726777f47ac4bba3e21b075905959bbea47e72eerikabele<xsl:template match="modulefilelist">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:text># Mapping from directive names to URLs</xsl:text>&lf;
a32843995c13450ba9433b733242977cb4970265nd<xsl:text># GENERATED FROM XML -- DO NOT EDIT</xsl:text>&lf;
a32843995c13450ba9433b733242977cb4970265nd<xsl:text># You may use it as follows:</xsl:text>&lf;
a32843995c13450ba9433b733242977cb4970265nd<xsl:text># RewriteEngine On</xsl:text>&lf;
a32843995c13450ba9433b733242977cb4970265nd<xsl:text># RewriteMap dir2url </xsl:text>
a32843995c13450ba9433b733242977cb4970265nd<xsl:text>txt:/path/to/convenience.map</xsl:text>&lf;
a32843995c13450ba9433b733242977cb4970265nd<xsl:text># RewriteCond ${dir2url:$1} (.+)</xsl:text>&lf;
a32843995c13450ba9433b733242977cb4970265nd<xsl:text># RewriteRule ^/+([^/]+)$ /manual/%1 [R=301,NE,L]</xsl:text>&lf;&lf;
a32843995c13450ba9433b733242977cb4970265nd
8a72c24379e10c3f3d0dfe352bf15e45ee65c179nd<xsl:apply-templates
a8571599bf3a6921cc0b9f609009e4ec1f59e1d0nd select="document(modulefile)/modulesynopsis[status!='Obsolete']
a8571599bf3a6921cc0b9f609009e4ec1f59e1d0nd /directivesynopsis[not(@location)]">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:sort select="name" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:apply-templates>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
a8571599bf3a6921cc0b9f609009e4ec1f59e1d0nd</xsl:template>
a8571599bf3a6921cc0b9f609009e4ec1f59e1d0nd<!-- /modulefilelist -->
f1110149b5b6c28ecc39d1958d98ad9cfa8e41f3nd
f1110149b5b6c28ecc39d1958d98ad9cfa8e41f3nd<!-- ==================================================================== -->
3726777f47ac4bba3e21b075905959bbea47e72eerikabele<!-- <directivesynopsis> -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:template match="directivesynopsis">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
3726777f47ac4bba3e21b075905959bbea47e72eerikabele <xsl:value-of select="translate(name, $uppercase, $lowercase)" />
8cfbcde8e416fd60132dd4324c42a5098da156cfnd <xsl:text>&#9;mod/</xsl:text>
8cfbcde8e416fd60132dd4324c42a5098da156cfnd <xsl:value-of select="/name" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:text>.html#</xsl:text>
3726777f47ac4bba3e21b075905959bbea47e72eerikabele <xsl:value-of select="translate(name, $uppercase, $lowercase)" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd &lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:template>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- /directivesynopsis -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:stylesheet>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd