quickreference.xsl revision 480bee29abcc415b6b8c18d2ecbf2c5f88f1f05b
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive<?xml version="1.0"?>
643d9e63923382336d6fcbcb3835fc6a50d0e93dnd<!DOCTYPE xsl:stylesheet [ <!ENTITY nbsp "&#160;"> ]>
d25f483469fdeb2ca813928eec854375b2eb65cdnd<xsl:stylesheet version="1.0"
643d9e63923382336d6fcbcb3835fc6a50d0e93dnd xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
643d9e63923382336d6fcbcb3835fc6a50d0e93dnd xmlns="http://www.w3.org/1999/xhtml">
643d9e63923382336d6fcbcb3835fc6a50d0e93dnd
a7835c7a8cf86045fdaee65dc2839bfe6314fb1end <!-- -->
a7835c7a8cf86045fdaee65dc2839bfe6314fb1end <!-- <quickreference> -->
db878466c5e95073429dda0bdd001f45e9486e16fielding <!-- Builds the directive quickreference page -->
db878466c5e95073429dda0bdd001f45e9486e16fielding <!-- -->
db878466c5e95073429dda0bdd001f45e9486e16fielding <xsl:template match="quickreference">
db878466c5e95073429dda0bdd001f45e9486e16fielding <html xml:lang="{$messages/@lang}" lang="{$messages/@lang}">
db878466c5e95073429dda0bdd001f45e9486e16fielding <xsl:call-template name="head"/>
db878466c5e95073429dda0bdd001f45e9486e16fielding
a7835c7a8cf86045fdaee65dc2839bfe6314fb1end <body id="directive-index">
a7835c7a8cf86045fdaee65dc2839bfe6314fb1end <xsl:call-template name="top"/>
a7835c7a8cf86045fdaee65dc2839bfe6314fb1end
a7835c7a8cf86045fdaee65dc2839bfe6314fb1end <div id="preamble">
a7835c7a8cf86045fdaee65dc2839bfe6314fb1end <h1>
a7835c7a8cf86045fdaee65dc2839bfe6314fb1end <xsl:value-of select="title"/>
a7835c7a8cf86045fdaee65dc2839bfe6314fb1end </h1>
a7835c7a8cf86045fdaee65dc2839bfe6314fb1end
a7835c7a8cf86045fdaee65dc2839bfe6314fb1end <xsl:apply-templates select="summary" />
a7835c7a8cf86045fdaee65dc2839bfe6314fb1end </div> <!-- /preamble -->
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive<xsl:text>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive</xsl:text> <!-- insert a line break -->
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <div id="directive-ref">
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <xsl:variable name="directives" select="document(sitemap/category[@id='modules']/modulefilelist/modulefile)/modulesynopsis[status!='Obsolete']/directivesynopsis[not(@location)]"/>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <!-- first collect the start letters -->
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <xsl:variable name="start-letters">
b3137f48abe3090c5531392e57ff0fefd76f59ebnd <xsl:call-template name="directive-startletters">
b3137f48abe3090c5531392e57ff0fefd76f59ebnd <xsl:with-param name="directives" select="$directives"/>
117a9c5156c08125e2060ff892adac4634b7ad2dnd </xsl:call-template>
117a9c5156c08125e2060ff892adac4634b7ad2dnd </xsl:variable>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <table id="legend">
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <tr>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <td class="letters"><span>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <xsl:call-template name="letter-bar">
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <xsl:with-param name="letters" select="$start-letters"/>
87ea898bcffe2ef490e833dc246a1cc0465d783fslive <xsl:with-param name="first" select="true()"/>
5e9423b4ca454c6416a2dc465dea1b1d34cec7a9slive </xsl:call-template>
1cb160a981947e75a8353da3fe40a653aa87100eslive </span></td>
1cb160a981947e75a8353da3fe40a653aa87100eslive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive<xsl:text>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive</xsl:text> <!-- insert a line break -->
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
f5d245e2129454d0fcaa77e21de055a30ea8a9c7slive <td>
46d1ef8cb385aa2f519ce7d355afc51f144bd938slive <xsl:apply-templates select="legend/table[position()=1]"/>
1cb160a981947e75a8353da3fe40a653aa87100eslive </td>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive <td>
f5d245e2129454d0fcaa77e21de055a30ea8a9c7slive <xsl:apply-templates select="legend/table[position()=2]"/>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive </td>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive </tr>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive </table>
5e9423b4ca454c6416a2dc465dea1b1d34cec7a9slive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive<xsl:text>
1c6a10274e908898347be82bc82bc7ae18c66410slive</xsl:text> <!-- insert a line break -->
1c6a10274e908898347be82bc82bc7ae18c66410slive
1c6a10274e908898347be82bc82bc7ae18c66410slive <table class="qref">
1c6a10274e908898347be82bc82bc7ae18c66410slive <xsl:call-template name="reference-of-letter">
1c6a10274e908898347be82bc82bc7ae18c66410slive <xsl:with-param name="letters-todo" select="$start-letters"/>
1c6a10274e908898347be82bc82bc7ae18c66410slive <xsl:with-param name="offset" select="number(0)"/>
1c6a10274e908898347be82bc82bc7ae18c66410slive <xsl:with-param name="directives" select="$directives"/>
1c6a10274e908898347be82bc82bc7ae18c66410slive </xsl:call-template>
1c6a10274e908898347be82bc82bc7ae18c66410slive </table>
1c6a10274e908898347be82bc82bc7ae18c66410slive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive </div> <!-- /directive-ref -->
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <xsl:call-template name="bottom"/>
46d1ef8cb385aa2f519ce7d355afc51f144bd938slive </body>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive </html>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive </xsl:template>
f5d245e2129454d0fcaa77e21de055a30ea8a9c7slive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <!-- -->
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <!-- the working horse. builds rows of all directives -->
1c6a10274e908898347be82bc82bc7ae18c66410slive <!-- starting with one letter -->
1c6a10274e908898347be82bc82bc7ae18c66410slive <!-- when done, it calls itself to catch the next letter -->
b3137f48abe3090c5531392e57ff0fefd76f59ebnd <!-- -->
1c6a10274e908898347be82bc82bc7ae18c66410slive <xsl:template name="reference-of-letter">
b3137f48abe3090c5531392e57ff0fefd76f59ebnd <xsl:param name="letters-todo"/>
1c6a10274e908898347be82bc82bc7ae18c66410slive <xsl:param name="offset"/>
b3137f48abe3090c5531392e57ff0fefd76f59ebnd <xsl:param name="directives"/>
1c6a10274e908898347be82bc82bc7ae18c66410slive
b3137f48abe3090c5531392e57ff0fefd76f59ebnd <xsl:variable name="letter" select="substring($letters-todo,1,1)"/>
1c6a10274e908898347be82bc82bc7ae18c66410slive
1c6a10274e908898347be82bc82bc7ae18c66410slive <xsl:for-each select="$directives[$letter=translate(substring(normalize-space(name),1,1),$lowercase,$uppercase)]">
1c6a10274e908898347be82bc82bc7ae18c66410slive <xsl:sort select="name"/>
1c6a10274e908898347be82bc82bc7ae18c66410slive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <tr>
b3137f48abe3090c5531392e57ff0fefd76f59ebnd <xsl:if test="position() mod 2 = $offset">
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <xsl:attribute name="class">odd</xsl:attribute>
b3137f48abe3090c5531392e57ff0fefd76f59ebnd </xsl:if>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
b3137f48abe3090c5531392e57ff0fefd76f59ebnd <td>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <a href="{/name}.html#{translate(name,$uppercase,$lowercase)}">
b3137f48abe3090c5531392e57ff0fefd76f59ebnd <xsl:if test="position()=1">
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive <xsl:attribute name="id"><xsl:value-of select="$letter"/></xsl:attribute>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive <xsl:attribute name="name"><xsl:value-of select="$letter"/></xsl:attribute>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive </xsl:if>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <xsl:apply-templates select="syntax"/>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive </a>
5e9423b4ca454c6416a2dc465dea1b1d34cec7a9slive </td>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
368bcafaedaee463f769c1b5f3547b9970df90d0slive <td>
368bcafaedaee463f769c1b5f3547b9970df90d0slive <xsl:value-of select="substring(substring-after(concat(default,' '),name),1,20)"/>
368bcafaedaee463f769c1b5f3547b9970df90d0slive <xsl:if test="string-length(substring-after(concat(default,' '),name)) &gt; 20">
27b8489f5fe26106de6a15fd68928797939d6610fielding <xsl:text> +</xsl:text>
27b8489f5fe26106de6a15fd68928797939d6610fielding </xsl:if>
27b8489f5fe26106de6a15fd68928797939d6610fielding </td>
27b8489f5fe26106de6a15fd68928797939d6610fielding
27b8489f5fe26106de6a15fd68928797939d6610fielding <td>
27b8489f5fe26106de6a15fd68928797939d6610fielding <xsl:if test="contextlist/context[normalize-space(.)='server config']">s</xsl:if>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive <xsl:if test="contextlist/context[normalize-space(.)='virtual host']">v</xsl:if>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive <xsl:if test="contextlist/context[normalize-space(.)='directory']">d</xsl:if>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive <xsl:if test="contextlist/context[normalize-space(.)='.htaccess']">h</xsl:if>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive </td>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive <td>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive <xsl:choose>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive <xsl:when test="/status='Base'">B</xsl:when>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive <xsl:when test="/status='MPM'">M</xsl:when>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive <xsl:when test="/status='Core'">C</xsl:when>
b51bf223f42d43ca6b1b33c95124edcfa5a871a4nd <xsl:when test="/status='Extension'">E</xsl:when>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive <xsl:when test="/status='Experimental'">X</xsl:when>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive </xsl:choose>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive </td>
0097a4f3e468c0192a2ce52ffee7bc8cea0a620bslive </tr>
368bcafaedaee463f769c1b5f3547b9970df90d0slive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <tr>
5e9423b4ca454c6416a2dc465dea1b1d34cec7a9slive <xsl:if test="position() mod 2 = $offset">
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <xsl:attribute name="class">odd</xsl:attribute>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive </xsl:if>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <td colspan="4" class="descr"><xsl:choose>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <xsl:when test="string-length(normalize-space(description)) &gt; 0">
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <xsl:apply-templates select="description"/>
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive </xsl:when>
27d00945ba0085e3d3ba2d329e51f61f242bc91and
2f9338296f846174ea5c8eab620399071afaef1bslive <xsl:otherwise>
d25f483469fdeb2ca813928eec854375b2eb65cdnd <xsl:text>-</xsl:text>
d25f483469fdeb2ca813928eec854375b2eb65cdnd </xsl:otherwise></xsl:choose>
27d00945ba0085e3d3ba2d329e51f61f242bc91and </td>
27d00945ba0085e3d3ba2d329e51f61f242bc91and </tr>
27d00945ba0085e3d3ba2d329e51f61f242bc91and
27d00945ba0085e3d3ba2d329e51f61f242bc91and<xsl:text>
d25f483469fdeb2ca813928eec854375b2eb65cdnd</xsl:text> <!-- insert a line break -->
2f9338296f846174ea5c8eab620399071afaef1bslive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive </xsl:for-each> <!-- /directives -->
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <!-- call next letter, if there is -->
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <xsl:if test="string-length($letters-todo) &gt; 1">
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <xsl:call-template name="reference-of-letter">
3fa58e00171aebf3b2cfa90035ed530f5b1f651dslive <xsl:with-param name="letters-todo" select="substring($letters-todo,2)"/>
ff83017b97bb6d5f49f00fb2fa598d8d2a24feb3nd <xsl:with-param name="offset" select="(count($directives[$letter=translate(substring(normalize-space(name),1,1),$lowercase,$uppercase)]) + $offset) mod 2"/>
ff83017b97bb6d5f49f00fb2fa598d8d2a24feb3nd <xsl:with-param name="directives" select="$directives"/>
ff83017b97bb6d5f49f00fb2fa598d8d2a24feb3nd </xsl:call-template>
ff83017b97bb6d5f49f00fb2fa598d8d2a24feb3nd </xsl:if>
ff83017b97bb6d5f49f00fb2fa598d8d2a24feb3nd
ff83017b97bb6d5f49f00fb2fa598d8d2a24feb3nd </xsl:template>
ff83017b97bb6d5f49f00fb2fa598d8d2a24feb3nd <!-- /reference-of-letter -->
ff83017b97bb6d5f49f00fb2fa598d8d2a24feb3nd
ff83017b97bb6d5f49f00fb2fa598d8d2a24feb3nd</xsl:stylesheet>
ff83017b97bb6d5f49f00fb2fa598d8d2a24feb3nd