aboutsummaryrefslogtreecommitdiff
path: root/share/xsl/freebsd-xhtml-common.xsl
diff options
context:
space:
mode:
authorGabor Kovesdan <gabor@FreeBSD.org>2013-04-05 20:14:52 +0000
committerGabor Kovesdan <gabor@FreeBSD.org>2013-04-05 20:14:52 +0000
commit61d924c5e2580ad44aaa17bc83bf4a752f886303 (patch)
tree27f344d72ed43fba9f5b94a15e992cf4a3b3c4dd /share/xsl/freebsd-xhtml-common.xsl
parentd518220b5898c12cff1bd74e93538c8b3ba48021 (diff)
- Better support I18N
Notes
svn path=/projects/xml-tools/; revision=41379
Diffstat (limited to 'share/xsl/freebsd-xhtml-common.xsl')
-rw-r--r--share/xsl/freebsd-xhtml-common.xsl42
1 files changed, 39 insertions, 3 deletions
diff --git a/share/xsl/freebsd-xhtml-common.xsl b/share/xsl/freebsd-xhtml-common.xsl
index d1261946bb..6009a3a022 100644
--- a/share/xsl/freebsd-xhtml-common.xsl
+++ b/share/xsl/freebsd-xhtml-common.xsl
@@ -29,6 +29,14 @@
<xsl:param name="make.valid.html" select="1"/>
<xsl:param name="html.cleanup" select="1"/>
+ <xsl:param name="local.l10n.xml" select="document('')"/>
+ <i18n xmlns="http://docbook.sourceforge.net/xmlns/l10n/1.0">
+ <l:l10n xmlns:l="http://docbook.sourceforge.net/xmlns/l10n/1.0" language="en">
+ <l:gentext key="Lastmodified" text="Last modified"/>
+ <l:gentext key="on" text="on"/>
+ </l:l10n>
+ </i18n>
+
<xsl:template name="user.footer.navigation">
<p align="center"><small>This, and other documents, can be downloaded
from <a href="ftp://ftp.FreeBSD.org/pub/FreeBSD/doc/">ftp://ftp.FreeBSD.org/pub/FreeBSD/doc/</a></small></p>
@@ -151,7 +159,11 @@
<xsl:template name="titlepage.releaseinfo">
<xsl:variable name="rev" select="str:split(., ' ')[3]"/>
- Current Revision:
+ <xsl:call-template name="gentext">
+ <xsl:with-param name="key" select="'Revision'"/>
+ </xsl:call-template>
+ <xsl:text>:</xsl:text>
+ <xsl:call-template name="gentext.space"/>
<xsl:call-template name="svnref.genlink">
<xsl:with-param name="repo" select="'doc'"/>
<xsl:with-param name="rev" select="$rev"/>
@@ -162,7 +174,7 @@
<xsl:variable name="pubdate">
<xsl:choose>
<xsl:when test="contains(., '$FreeBSD')">
- <xsl:value-of select="str:split(., ' ')[4]"/> by <xsl:value-of select="str:split(., ' ')[6]"/>
+ <xsl:value-of select="str:split(., ' ')[4]"/>
</xsl:when>
<xsl:otherwise>
@@ -170,6 +182,30 @@
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
- Last modified on <xsl:value-of select="$pubdate"/>.
+
+ <xsl:variable name="committer">
+ <xsl:if test="contains(., '$FreeBSD')">
+ <xsl:value-of select="str:split(., ' ')[6]"/>
+ </xsl:if>
+ </xsl:variable>
+
+ <xsl:call-template name="gentext">
+ <xsl:with-param name="key" select="'Lastmodified'"/>
+ </xsl:call-template>
+ <xsl:call-template name="gentext.space"/>
+ <xsl:call-template name="gentext">
+ <xsl:with-param name="key" select="'on'"/>
+ </xsl:call-template>
+ <xsl:call-template name="gentext.space"/>
+ Last modified on <xsl:value-of select="$pubdate"/>
+ <xsl:if test="$committer">
+ <xsl:call-template name="gentext.space"/>
+ <xsl:value-of select="$committer"/>
+ <xsl:call-template name="gentext.space"/>
+ <xsl:call-template name="gentext">
+ <xsl:with-param name="key" select="'by'"/>
+ </xsl:call-template>
+ </xsl:if>
+ <xsl:text>.</xsl:text>
</xsl:template>
</xsl:stylesheet>