Mercurial > hg > nginx-site
annotate xsls/link.xsls @ 72:0987079ad08f
- "try_files" can be specified in the "server" context,
- "types_hash_bucket_size", "types_hash_max_size",
"variables_hash_bucket_size", "variables_hash_max_size" are documented.
author | Ruslan Ermilov <ru@nginx.com> |
---|---|
date | Mon, 10 Oct 2011 09:23:09 +0000 |
parents | 12f1de4539b4 |
children | 56457a474903 |
rev | line source |
---|---|
0
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
1 X:stylesheet { |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
2 |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
3 |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
4 <!-- {a href="/en/docs/page.xml" /} --> |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
5 |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
6 X:template = "a[starts-with(@href, '/') |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
7 and string() = '' |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
8 and contains(@href, '.xml')]" |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
9 { |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
10 <a> |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
11 X:attribute "href" { |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
12 |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
13 <!-- |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
14 -- variables are not allowed in a template match predicate: |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
15 -- a[starts-with(@href, $DIRNAME) ... ] |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
16 -- therefore, we have to test this using "if" |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
17 --> |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
18 |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
19 X:if "starts-with(@href, $DIRNAME)" { |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
20 |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
21 <!-- convert to a link "docs/page.html" --> |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
22 |
22
9d3403f5204d
nginx-1.1.3, ngx_http_mp4_module
Igor Sysoev <igor@sysoev.ru>
parents:
0
diff
changeset
|
23 !{ substring-after(document(concat($XML, @href))/article/@link |
9d3403f5204d
nginx-1.1.3, ngx_http_mp4_module
Igor Sysoev <igor@sysoev.ru>
parents:
0
diff
changeset
|
24 |document(concat($XML, @href))/module/@link, |
0
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
25 $DIRNAME) } |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
26 } else { |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
27 |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
28 <!-- convert to a link "../../../en/docs/page.html" --> |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
29 |
22
9d3403f5204d
nginx-1.1.3, ngx_http_mp4_module
Igor Sysoev <igor@sysoev.ru>
parents:
0
diff
changeset
|
30 !{ concat($ROOT, document(concat($XML, @href))/article/@link |
9d3403f5204d
nginx-1.1.3, ngx_http_mp4_module
Igor Sysoev <igor@sysoev.ru>
parents:
0
diff
changeset
|
31 |document(concat($XML, @href))/module/@link) } |
0
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
32 } |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
33 } |
32
2bcfb5f75e06
Supporting new format of <module> and <section>:
Igor Sysoev <igor@sysoev.ru>
parents:
22
diff
changeset
|
34 !{ document(concat($XML, @href))/article/@title |
2bcfb5f75e06
Supporting new format of <module> and <section>:
Igor Sysoev <igor@sysoev.ru>
parents:
22
diff
changeset
|
35 |document(concat($XML, @href))/article/@name |
2bcfb5f75e06
Supporting new format of <module> and <section>:
Igor Sysoev <igor@sysoev.ru>
parents:
22
diff
changeset
|
36 |document(concat($XML, @href))/module/@title |
2bcfb5f75e06
Supporting new format of <module> and <section>:
Igor Sysoev <igor@sysoev.ru>
parents:
22
diff
changeset
|
37 |document(concat($XML, @href))/module/@name } |
0
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
38 </a> |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
39 } |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
40 |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
41 |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
42 <!-- {a href="/en/docs/page.xml"} TEXT {/a} --> |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
43 |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
44 X:template = "a[starts-with(@href, '/') |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
45 and string() |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
46 and contains(@href, '.xml')]" |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
47 { |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
48 <a> |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
49 X:attribute "href" { |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
50 X:if "starts-with(@href, $DIRNAME)" { |
22
9d3403f5204d
nginx-1.1.3, ngx_http_mp4_module
Igor Sysoev <igor@sysoev.ru>
parents:
0
diff
changeset
|
51 !{ substring-after(document(concat($XML, @href))/article/@link |
9d3403f5204d
nginx-1.1.3, ngx_http_mp4_module
Igor Sysoev <igor@sysoev.ru>
parents:
0
diff
changeset
|
52 |document(concat($XML, @href))/module/@link, |
0
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
53 $DIRNAME) } |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
54 } else { |
22
9d3403f5204d
nginx-1.1.3, ngx_http_mp4_module
Igor Sysoev <igor@sysoev.ru>
parents:
0
diff
changeset
|
55 !{ concat($ROOT, document(concat($XML, @href))/article/@link |
9d3403f5204d
nginx-1.1.3, ngx_http_mp4_module
Igor Sysoev <igor@sysoev.ru>
parents:
0
diff
changeset
|
56 |document(concat($XML, @href))/module/@link) } |
0
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
57 } |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
58 } |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
59 !!; |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
60 </a> |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
61 } |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
62 |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
63 X:template = "a" { <a href="{@href}"> !!; </a> } |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
64 |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
65 X:template = "img" { <img src="{@href}"> !!; </img> } |
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
66 |
52
666e85596e3c
Added support for <link url="..."> which should eventually replace
Ruslan Ermilov <ru@nginx.com>
parents:
32
diff
changeset
|
67 X:template = "link[@url]" { <a href="{@url}"> !!; </a> } |
666e85596e3c
Added support for <link url="..."> which should eventually replace
Ruslan Ermilov <ru@nginx.com>
parents:
32
diff
changeset
|
68 |
57
12f1de4539b4
Initial English translation of ngx_http_core_module.
Ruslan Ermilov <ru@nginx.com>
parents:
52
diff
changeset
|
69 X:template = "link[@id and not(@doc)]" { <a href="#{@id}"> !!; </a> } |
12f1de4539b4
Initial English translation of ngx_http_core_module.
Ruslan Ermilov <ru@nginx.com>
parents:
52
diff
changeset
|
70 |
12f1de4539b4
Initial English translation of ngx_http_core_module.
Ruslan Ermilov <ru@nginx.com>
parents:
52
diff
changeset
|
71 X:template = "link[@doc and not(@id)]" { |
12f1de4539b4
Initial English translation of ngx_http_core_module.
Ruslan Ermilov <ru@nginx.com>
parents:
52
diff
changeset
|
72 <a href="{substring-before(@doc, '.xml')}.html"> !!; </a> |
0
61e04fc01027
Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
73 } |
57
12f1de4539b4
Initial English translation of ngx_http_core_module.
Ruslan Ermilov <ru@nginx.com>
parents:
52
diff
changeset
|
74 |
12f1de4539b4
Initial English translation of ngx_http_core_module.
Ruslan Ermilov <ru@nginx.com>
parents:
52
diff
changeset
|
75 X:template = "link[@id and @doc]" { |
12f1de4539b4
Initial English translation of ngx_http_core_module.
Ruslan Ermilov <ru@nginx.com>
parents:
52
diff
changeset
|
76 <a href="{substring-before(@doc, '.xml')}.html#{@id}"> !!; </a> |
12f1de4539b4
Initial English translation of ngx_http_core_module.
Ruslan Ermilov <ru@nginx.com>
parents:
52
diff
changeset
|
77 } |
12f1de4539b4
Initial English translation of ngx_http_core_module.
Ruslan Ermilov <ru@nginx.com>
parents:
52
diff
changeset
|
78 |
12f1de4539b4
Initial English translation of ngx_http_core_module.
Ruslan Ermilov <ru@nginx.com>
parents:
52
diff
changeset
|
79 } |