From: | "Sven Vermeulen (swift)" <swift@g.o> |
---|---|
To: | gentoo-commits@l.g.o |
Subject: | [gentoo-commits] gentoo commit in xml/htdocs/xsl: guide.xsl |
Date: | Tue, 29 Nov 2011 18:57:37 |
Message-Id: | 20111129185717.C9A7C2004B@flycatcher.gentoo.org |
1 | swift 11/11/29 18:57:17 |
2 | |
3 | Modified: guide.xsl |
4 | Log: |
5 | Support <license version="2.5" /> and ..."3.0" tags |
6 | |
7 | With the DTD now supporting the version attribute, we now include support for the license version in the stylesheets, so |
8 | that a document using this tag correctly displays the right license information. |
9 | |
10 | Revision Changes Path |
11 | 1.252 xml/htdocs/xsl/guide.xsl |
12 | |
13 | file : http://sources.gentoo.org/viewvc.cgi/gentoo/xml/htdocs/xsl/guide.xsl?rev=1.252&view=markup |
14 | plain: http://sources.gentoo.org/viewvc.cgi/gentoo/xml/htdocs/xsl/guide.xsl?rev=1.252&content-type=text/plain |
15 | diff : http://sources.gentoo.org/viewvc.cgi/gentoo/xml/htdocs/xsl/guide.xsl?r1=1.251&r2=1.252 |
16 | |
17 | Index: guide.xsl |
18 | =================================================================== |
19 | RCS file: /var/cvsroot/gentoo/xml/htdocs/xsl/guide.xsl,v |
20 | retrieving revision 1.251 |
21 | retrieving revision 1.252 |
22 | diff -u -r1.251 -r1.252 |
23 | --- guide.xsl 1 Apr 2011 04:49:18 -0000 1.251 |
24 | +++ guide.xsl 29 Nov 2011 18:57:17 -0000 1.252 |
25 | @@ -1562,12 +1562,29 @@ |
26 | <xsl:if test="$RTL='Y'"> |
27 | <xsl:attribute name="dir">RTL</xsl:attribute> |
28 | </xsl:if> |
29 | - <xsl:apply-templates select="func:gettext('License')"/> |
30 | + <xsl:choose> |
31 | + <xsl:when test="@version='2.5'"> |
32 | + <xsl:apply-templates select="func:gettext('License-2.5')"/> |
33 | + </xsl:when> |
34 | + <xsl:when test="@version='3.0'"> |
35 | + <xsl:apply-templates select="func:gettext('License-3.0')"/> |
36 | + </xsl:when> |
37 | + <xsl:otherwise> |
38 | + <xsl:apply-templates select="func:gettext('License')"/> |
39 | + </xsl:otherwise> |
40 | + </xsl:choose> |
41 | </p> |
42 | <xsl:comment> |
43 | <rdf:RDF xmlns="http://web.resource.org/cc/" |
44 | xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"> |
45 | - <License rdf:about="http://creativecommons.org/licenses/by-sa/2.5/"> |
46 | + <xsl:choose> |
47 | + <xsl:when test="@version"> |
48 | + <License rdf:about="http://creativecommons.org/licenses/by-sa/<xsl:value-of select="@version" />/"> |
49 | + </xsl:when> |
50 | + <xsl:otherwise> |
51 | + <license rdf:about="http://creativecommons.org/licenses/by-sa/2.5/"> |
52 | + </xsl:otherwise> |
53 | + </xsl:choose> |
54 | <permits rdf:resource="http://web.resource.org/cc/Reproduction" /> |
55 | <permits rdf:resource="http://web.resource.org/cc/Distribution" /> |
56 | <requires rdf:resource="http://web.resource.org/cc/Notice" /> |