comparison xslt/download.xslt @ 170:cd2698ea00ab

Added generated XSLTs.
author Ruslan Ermilov <ru@nginx.com>
date Wed, 02 Nov 2011 19:31:11 +0000
parents
children 1507ec5ba69a
comparison
equal deleted inserted replaced
169:b7b160e4e046 170:cd2698ea00ab
1 <?xml version="1.0" encoding="utf-8"?>
2 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
3
4 <xsl:output indent="no" version="4.0" encoding="utf-8" method="html"/>
5
6 <xsl:strip-space elements="*"/>
7
8 <xsl:param select="'../xml'" name="XML"/>
9
10 <xsl:param name="YEAR"/>
11
12 <xsl:variable select="/article/@link" name="LINK"/>
13
14 <xsl:include href="dirname.xslt"/>
15
16 <xsl:include href="link.xslt"/>
17
18 <xsl:include href="style.xslt"/>
19
20 <xsl:include href="body.xslt"/>
21
22 <xsl:include href="menu.xslt"/>
23
24 <xsl:include href="content.xslt"/>
25
26 <xsl:template match="/article">
27
28 <html>
29 <head>
30
31 <title>
32 <xsl:value-of select="@name"/>
33 </title>
34
35 <xsl:call-template name="style">
36 <xsl:with-param select="@lang" name="lang"/>
37 </xsl:call-template>
38
39 </head>
40
41 <xsl:call-template name="body">
42 <xsl:with-param select="@lang" name="lang"/>
43 </xsl:call-template>
44
45 </html>
46 </xsl:template>
47
48 <xsl:template match="download">
49 <table width="100%">
50 <xsl:apply-templates select="item"/>
51 </table>
52 </xsl:template>
53
54 <xsl:template match="download/item[position() &lt;= ../@last]">
55
56 <tr>
57
58 <td width="20%">
59
60 <xsl:if test="position() = 1">
61
62 <a>
63
64 <xsl:attribute name="href">
65 <xsl:text>/</xsl:text>
66 <xsl:value-of select="/article/@lang"/>
67 <xsl:text>/</xsl:text>
68 <xsl:value-of select="../@changes"/>
69 </xsl:attribute>
70
71 <xsl:value-of select="../@changes"/>
72
73 </a>
74 </xsl:if>
75
76 </td>
77
78 <td width="20%">
79
80 <a>
81
82 <xsl:attribute name="href">
83
84 <xsl:text>/download/nginx-</xsl:text>
85 <xsl:value-of select="@ver"/>
86 <xsl:text>.tar.gz</xsl:text>
87 </xsl:attribute>
88
89 <xsl:text>nginx-</xsl:text>
90 <xsl:value-of select="@ver"/>
91
92 </a>
93
94 <xsl:if test="@pgp = 'yes'">
95
96 <xsl:text>  </xsl:text>
97
98 <a>
99
100 <xsl:attribute name="href">
101
102 <xsl:text>/download/nginx-</xsl:text>
103 <xsl:value-of select="@ver"/>
104 <xsl:text>.tar.gz.asc</xsl:text>
105 </xsl:attribute>
106
107 <xsl:text>pgp</xsl:text>
108
109 </a>
110 </xsl:if>
111
112 </td>
113
114 <td>
115
116 <xsl:if test="@win= 'yes'">
117
118 <a>
119
120 <xsl:attribute name="href">
121
122 <xsl:text>/download/nginx-</xsl:text>
123 <xsl:value-of select="@ver"/>
124 <xsl:text>.zip</xsl:text>
125 </xsl:attribute>
126
127 <xsl:text>nginx/Windows-</xsl:text>
128 <xsl:value-of select="@ver"/>
129
130 </a>
131
132 <xsl:if test="@pgp = 'yes'">
133
134 <xsl:text>  </xsl:text>
135
136 <a>
137
138 <xsl:attribute name="href">
139
140 <xsl:text>/download/nginx-</xsl:text>
141 <xsl:value-of select="@ver"/>
142 <xsl:text>.zip.asc</xsl:text>
143 </xsl:attribute>
144
145 <xsl:text>pgp</xsl:text>
146
147 </a>
148 </xsl:if>
149 </xsl:if>
150
151 </td>
152
153 </tr>
154 </xsl:template>
155
156 <xsl:template match="download/item[position() &gt; ../@last]"/>
157
158 </xsl:stylesheet>