4
Licensed to the Apache Software Foundation (ASF) under one or more
5
contributor license agreements. See the NOTICE file distributed with
6
this work for additional information regarding copyright ownership.
7
The ASF licenses this file to You under the Apache License, Version 2.0
8
(the "License"); you may not use this file except in compliance with
9
the License. You may obtain a copy of the License at
11
http://www.apache.org/licenses/LICENSE-2.0
13
Unless required by applicable law or agreed to in writing, software
14
distributed under the License is distributed on an "AS IS" BASIS,
15
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16
See the License for the specific language governing permissions and
17
limitations under the License.
20
<!DOCTYPE xsl:stylesheet [
21
<!ENTITY lf SYSTEM "util/lf.xml">
23
<xsl:stylesheet version="1.0"
24
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
25
xmlns="http://www.w3.org/1999/xhtml">
27
<!-- ==================================================================== -->
28
<!-- <modulesynopsis> -->
29
<!-- Process an entire document into an HTML page -->
30
<!-- ==================================================================== -->
31
<xsl:template match="modulesynopsis">
32
<html xml:lang="{$doclang}" lang="{$doclang}">
33
<xsl:call-template name="head" />&lf;
36
<xsl:call-template name="top" />&lf;
38
<div id="page-content">&lf;
42
<xsl:when test="status='Core'">
43
<xsl:value-of select="$message
44
[@id='apachecore']" />
46
<xsl:when test="name='mpm_common'">
47
<xsl:value-of select="$message
48
[@id='apachempmcommon']" />
50
<xsl:when test="status='MPM'">
51
<xsl:value-of select="$message
53
<xsl:text> </xsl:text>
54
<xsl:call-template name="module-translatename">
55
<xsl:with-param name="name" select="name" />
59
<xsl:value-of select="$message
60
[@id='apachemodule']" />
61
<xsl:text> </xsl:text>
62
<xsl:value-of select="name" />
67
<xsl:call-template name="langavail" />&lf;
69
<!-- Description and module-headers -->
70
<table class="module">
73
<a href="module-dict.html#Description">
74
<xsl:value-of select="$message
75
[@id='description']" />
76
<xsl:text>:</xsl:text>
80
<xsl:apply-templates select="description" />
85
<a href="module-dict.html#Status">
86
<xsl:value-of select="$message
88
<xsl:text>:</xsl:text>
92
<xsl:value-of select="status" />
96
<xsl:if test="identifier">&lf;
99
<a href="module-dict.html#ModuleIdentifier">
100
<xsl:value-of select="$message
101
[@id='moduleidentifier']" />
102
<xsl:text>:</xsl:text>
106
<xsl:value-of select="identifier" />
111
<xsl:if test="sourcefile">&lf;
114
<a href="module-dict.html#SourceFile">
115
<xsl:value-of select="$message
116
[@id='sourcefile']" />
117
<xsl:text>:</xsl:text>
121
<xsl:value-of select="sourcefile" />
126
<xsl:if test="compatibility">&lf;
129
<a href="module-dict.html#Compatibility">
130
<xsl:value-of select="$message
131
[@id='compatibility']" />
132
<xsl:text>:</xsl:text>
136
<xsl:apply-templates select="compatibility" />
142
<!-- Summary of module features/usage (1 to 3 paragraphs, -->
144
<xsl:if test="summary">
146
<xsl:value-of select="$message
150
<xsl:apply-templates select="summary" />
152
</div>&lf; <!-- /#preamble -->
154
<xsl:if test="not($is-chm) or seealso">
156
<xsl:if test="not($is-chm)">
157
<h3 class="directives">
158
<xsl:value-of select="$message
159
[@id='directives']" />
163
<xsl:when test="directivesynopsis">
165
<xsl:for-each select="directivesynopsis">
166
<xsl:sort select="name" />
167
<xsl:variable name="lowername"
168
select="translate(name, $uppercase,
172
<xsl:when test="not(@location)">
174
<img src="{$path}/images/down.gif"
176
<xsl:text> </xsl:text>
177
<a href="#{$lowername}">
178
<xsl:if test="@type='section'"
180
<xsl:value-of select="name" />
181
<xsl:if test="@type='section'"
187
<xsl:variable name="lowerlocation"
188
select="translate(@location, $uppercase,
191
<img src="{$path}/images/right.gif"
193
<xsl:text> </xsl:text>
194
<a href="{$lowerlocation}.html#{
196
<xsl:if test="@type='section'"
198
<xsl:value-of select="name" />
199
<xsl:if test="@type='section'"
206
</ul>&lf; <!-- /toc -->
207
</xsl:when> <!-- have directives -->
211
<xsl:value-of select="$message
212
[@id='nodirectives']" />
217
<xsl:if test="section">
219
<xsl:value-of select="$message
225
select="section" mode="index" />
228
</xsl:if> <!-- /!is-chm -->
230
<xsl:if test="seealso">
232
<xsl:value-of select="$message
236
<ul class="seealso">&lf;
237
<xsl:for-each select="seealso">
239
<xsl:apply-templates />
244
</div> <!-- /#quickview -->
245
</xsl:if>&lf; <!-- have sidebar -->
247
<!-- Sections of documentation about the module as a whole -->
248
<xsl:apply-templates select="section" />&lf;
250
<!-- Directive documentation -->
251
<xsl:apply-templates select="directivesynopsis">
252
<xsl:sort select="name" />
253
</xsl:apply-templates>
254
</div>&lf; <!-- /#page-content -->
256
<xsl:call-template name="bottom" />&lf;
260
<!-- /modulesynopsis -->
263
<!-- ==================================================================== -->
264
<!-- Directivesynopsis -->
265
<!-- ==================================================================== -->
266
<xsl:template match="directivesynopsis">
267
<xsl:if test="not(@location)">
268
<xsl:call-template name="toplink" />&lf;
270
<div class="directive-section">
271
<xsl:variable name="lowername"
272
select="translate(name, $uppercase, $lowercase)" />
274
<!-- Directive heading gets both mixed case and lowercase -->
275
<!-- anchors, and includes lt/gt only for "section" directives -->
277
<a id="{name}" name="{name}">
278
<xsl:if test="@type='section'"><</xsl:if>
279
<xsl:value-of select="name" />
280
<xsl:if test="@type='section'">></xsl:if>
284
<xsl:when test="$message
285
[@id='directive']/@replace-space-with">
286
<xsl:value-of select="$message
287
[@id='directive']/@replace-space-with"/>
290
<xsl:text> </xsl:text>
294
<a id="{$lowername}" name="{$lowername}">
295
<xsl:value-of select="$message[@id='directive']" />
299
<!-- Directive header -->
300
<table class="directive">&lf;
303
<a href="directive-dict.html#Description">
304
<xsl:value-of select="$message
305
[@id='description']" />
306
<xsl:text>:</xsl:text>
310
<xsl:apply-templates select="description" />
316
<a href="directive-dict.html#Syntax">
317
<xsl:value-of select="$message[@id='syntax']" />
318
<xsl:text>:</xsl:text>
323
<xsl:apply-templates select="syntax" />
328
<xsl:if test="default">&lf;
331
<a href="directive-dict.html#Default">
332
<xsl:value-of select="$message[@id='default']" />
333
<xsl:text>:</xsl:text>
338
<xsl:apply-templates select="default" />
346
<a href="directive-dict.html#Context">
347
<xsl:value-of select="$message[@id='context']" />
348
<xsl:text>:</xsl:text>
352
<xsl:apply-templates select="contextlist" />
356
<xsl:if test="override">&lf;
359
<a href="directive-dict.html#Override">
360
<xsl:value-of select="$message[@id='override']"/>
361
<xsl:text>:</xsl:text>
365
<xsl:value-of select="override" />
372
<a href="directive-dict.html#Status">
373
<xsl:value-of select="$message[@id='status']" />
374
<xsl:text>:</xsl:text>
378
<xsl:value-of select="../status" />
384
<a href="directive-dict.html#Module">
385
<xsl:value-of select="$message[@id='module']" />
386
<xsl:text>:</xsl:text>
391
<xsl:when test="modulelist">
392
<xsl:apply-templates select="modulelist" />
395
<xsl:value-of select="../name" />
401
<xsl:if test="compatibility">&lf;
404
<a href="directive-dict.html#Compatibility">
405
<xsl:value-of select="$message
406
[@id='compatibility']" />
407
<xsl:text>:</xsl:text>
411
<xsl:apply-templates select="compatibility" />
417
<xsl:apply-templates select="usage" />&lf;
419
<xsl:if test="seealso">
421
<xsl:value-of select="$message[@id='seealso']" />
425
<xsl:for-each select="seealso">
427
<xsl:apply-templates />
432
</div>&lf; <!-- /.directive-section -->
435
<!-- /directivesynopsis -->
438
<!-- ==================================================================== -->
439
<!-- <contextlist> -->
440
<!-- ==================================================================== -->
441
<xsl:template match="contextlist">
442
<xsl:apply-templates select="context" />
444
<!-- /contextlist -->
447
<!-- ==================================================================== -->
449
<!-- Each entry is separeted with a comma -->
450
<!-- ==================================================================== -->
451
<xsl:template match="context">
453
<xsl:when test="normalize-space(.) = 'server config'">
454
<xsl:value-of select="$message[@id='serverconfig']" />
456
<xsl:when test="normalize-space(.) = 'virtual host'">
457
<xsl:value-of select="$message[@id='virtualhost']" />
459
<xsl:when test="normalize-space(.) = 'directory'">
460
<xsl:value-of select="$message[@id='directory']" />
462
<xsl:when test="normalize-space(.) = '.htaccess'">
463
<xsl:value-of select="$message[@id='htaccess']" />
465
<xsl:otherwise> <!-- error -->
466
<xsl:message terminate="yes">
467
unknown context: <xsl:value-of select="." />
472
<xsl:if test="position() != last()">
473
<xsl:text>, </xsl:text>
479
<!-- ==================================================================== -->
480
<!-- <modulelist> -->
481
<!-- ==================================================================== -->
482
<xsl:template match="modulelist">
483
<xsl:for-each select="module">
484
<xsl:call-template name="module" />
485
<xsl:if test="position() != last()">
486
<xsl:text>, </xsl:text>
493
<!-- ==================================================================== -->
494
<!-- modulesynopsis/compatibility -->
495
<!-- ==================================================================== -->
496
<xsl:template match="modulesynopsis/compatibility">
497
<xsl:apply-templates />
501
<!-- ==================================================================== -->
502
<!-- directivesynopsis/compatibility -->
503
<!-- ==================================================================== -->
504
<xsl:template match="directivesynopsis/compatibility">
505
<xsl:apply-templates />