New web page layout as prepared by Rainer.
svn path=/trunk/; revision=8196
This commit is contained in:
parent
396a19bc27
commit
1cd62a5b6d
220
fsfeurope.css
220
fsfeurope.css
@ -16,117 +16,169 @@
|
||||
|
||||
body {
|
||||
margin: 0;
|
||||
padding: 1em 0;
|
||||
padding: 0;
|
||||
background: #FDFDFD;
|
||||
color: #151515;
|
||||
font-family: Nimbus Sans L, Helvetica, Verdana, sans-serif;
|
||||
font-size: 100.01%; /* FIXME: What does this do? */
|
||||
font-size: 100.01%; /* Fix for IE */
|
||||
}
|
||||
|
||||
a {
|
||||
a, a:link {
|
||||
color: #202D79;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
a:visited {
|
||||
color: #314C14; /* like green mix, but darker */
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
a:hover, a:active, a:focus {
|
||||
color: #6BB340;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
/* avoid hover effects and borders on internal marks and graphical links */
|
||||
a[name], a[name]:hover, a.gl img, a.gl:link, a.gl:visited, a.gl:hover {
|
||||
border: none;
|
||||
background: #FDFDFD;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.page {
|
||||
margin: 0;
|
||||
padding: 0 0 2em 1em;
|
||||
}
|
||||
|
||||
/* invisible except in text based browsers */
|
||||
.n {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
/* Logo and Focus */
|
||||
/* Logo */
|
||||
/* ------------------------------------------------------------------------- */
|
||||
|
||||
td.focus-box {
|
||||
border-left: thin solid #202D79;
|
||||
.logo, .logo a, .logo a img {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.logo {
|
||||
margin: 1em 1em 1em 2em;
|
||||
}
|
||||
|
||||
.logo a, .logo a:link, .logo a:visited {
|
||||
border: none;
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
/* Menu */
|
||||
/* ------------------------------------------------------------------------- */
|
||||
|
||||
.menu {
|
||||
float: left;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
color: #151515;
|
||||
width: 13em;
|
||||
min-width: 180px; /* ignored by IE 6 */
|
||||
}
|
||||
|
||||
.menu ul {
|
||||
margin: 0;
|
||||
background: url(/graphics/bogen-sebastian-10-01.png) top left no-repeat;
|
||||
padding: 1em 0 1em 1.4em;
|
||||
}
|
||||
|
||||
.menu li {
|
||||
margin: 0.4em 0 0 0;
|
||||
list-style: none;
|
||||
}
|
||||
|
||||
.menu li a, .menu li a:link, .menu li a:visited {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.menu li.submenu {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.menu li.submenu a, .menu li.submenu a:link, .menu li.submenu a:visited {
|
||||
display: block;
|
||||
padding-left: 0.6em;
|
||||
}
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
/* Language List */
|
||||
/* ------------------------------------------------------------------------- */
|
||||
|
||||
td.line {
|
||||
border-top: thin solid #202D79;
|
||||
border-bottom: thin solid #202D79;
|
||||
.language {
|
||||
margin: 0 0 0 15em;
|
||||
padding: 0.3em 0 0.4em 0;
|
||||
text-align: center;
|
||||
font-size: 90%;
|
||||
}
|
||||
|
||||
.line a {
|
||||
text-decoration: none;
|
||||
.language ul {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.line a:visited {
|
||||
color: #202D79;
|
||||
}
|
||||
|
||||
.line a:hover, .line a:active, .line a:focus {
|
||||
background: #D0F400;
|
||||
}
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
/* Menu */
|
||||
/* ------------------------------------------------------------------------- */
|
||||
|
||||
td.menu {
|
||||
border-left: thin solid #202D79;
|
||||
width: 13em;
|
||||
padding: 1em;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
a.menu {
|
||||
text-decoration: none;
|
||||
font-size: 15px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
a.submenu {
|
||||
text-decoration: none;
|
||||
font-size: 13px;
|
||||
padding-left: 2em;
|
||||
}
|
||||
|
||||
a.menu:visited, a.submenu:visited {
|
||||
color: #202D79;
|
||||
}
|
||||
|
||||
a.menu:hover, a.menu:active, a.menu:focus, a.submenu:hover, a.submenu:active, a.submenu:focus {
|
||||
background: #D0F400;
|
||||
.language li {
|
||||
display: inline;
|
||||
margin: 0.3em;
|
||||
list-style: none;
|
||||
}
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
/* Content */
|
||||
/* ------------------------------------------------------------------------- */
|
||||
|
||||
td.body {
|
||||
padding: 0 1.5em;
|
||||
width: 99%;
|
||||
vertical-align: top;
|
||||
.content {
|
||||
margin: 3em 0 0 14em;
|
||||
padding: 0 1em 1em 1em;
|
||||
}
|
||||
|
||||
.body {
|
||||
margin-left 20px;
|
||||
margin-right 20px;
|
||||
}
|
||||
|
||||
.body h1 {
|
||||
.content h1 h2 {
|
||||
text-align: center;
|
||||
color: #202D79;
|
||||
}
|
||||
|
||||
.body h2 {
|
||||
margin-left 0px;
|
||||
.content h3 {
|
||||
color: #202D79;
|
||||
}
|
||||
|
||||
.body h3 {
|
||||
margin-left 0px;
|
||||
color: #202D79;
|
||||
.content img {
|
||||
float: right;
|
||||
margin: 0 0 1em 1em;
|
||||
}
|
||||
|
||||
.postit {
|
||||
float: left;
|
||||
margin: 0 1em 1em 0;
|
||||
border: 1px #000 solid;
|
||||
padding: 0.3em;
|
||||
width: 14em;
|
||||
background: #FFECBF;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
/* Footer */
|
||||
/* ------------------------------------------------------------------------- */
|
||||
|
||||
.footer {
|
||||
clear: both;
|
||||
border: 5px #FDFDFD solid; /* IE workaround */
|
||||
padding: 0.5em;
|
||||
font-size: 90%;
|
||||
}
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
/* Styles used only on some pages */
|
||||
/* ------------------------------------------------------------------------- */
|
||||
|
||||
/* News and event items */
|
||||
/* News and event items (old, based on table) */
|
||||
|
||||
table.news {
|
||||
margin: 0px;
|
||||
@ -151,6 +203,46 @@ td.newsdate {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
/* News and event items (new, based on dt and dd) */
|
||||
|
||||
.newsleft {
|
||||
float: left;
|
||||
width: 45%;
|
||||
}
|
||||
|
||||
.newsright {
|
||||
border: 1px #FDFDFD solid;
|
||||
padding-left: 47%;
|
||||
}
|
||||
|
||||
.newsleft dt, .newsright dt {
|
||||
padding: 0 0 1em 0;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.newsleft dt span, .newsright dt span {
|
||||
float: right;
|
||||
margin: 0 0 0 0.5em;
|
||||
padding: 0;
|
||||
color: #888;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
.newsleft dd, .newsright dd {
|
||||
margin: 0;
|
||||
padding: 0 0 2em 0;
|
||||
}
|
||||
|
||||
.newsleft dd ul, .newsright dd ul {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.newsleft dd li, .newsright dd li {
|
||||
padding-left: 0.5em;
|
||||
list-style: none;
|
||||
}
|
||||
|
||||
/* Project list */
|
||||
|
||||
th.projects {
|
||||
|
438
fsfeurope.xsl
438
fsfeurope.xsl
@ -1,219 +1,273 @@
|
||||
<?xml version="1.0" encoding="ISO-8859-1"?>
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<xsl:stylesheet version="1.0"
|
||||
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
|
||||
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
|
||||
|
||||
<xsl:output method="html"
|
||||
encoding="UTF-8"
|
||||
doctype-public="-//W3C//DTD HTML 4.0 Transitional//EN"
|
||||
doctype-system="http://www.w3.org/TR/REC-html40/loose.dtd"
|
||||
indent="yes"
|
||||
/>
|
||||
<xsl:output method="html" encoding="utf-8" indent="yes"
|
||||
doctype-public="-//W3C//DTD HTML 4.0 Transitional//EN"
|
||||
doctype-system="http://www.w3.org/TR/REC-html40/loose.dtd"/>
|
||||
|
||||
<!-- The top level element of the input file is "buildinfo" -->
|
||||
<xsl:template match="buildinfo">
|
||||
<xsl:apply-templates select="node()" />
|
||||
<xsl:apply-templates select="node()"/>
|
||||
</xsl:template>
|
||||
|
||||
<!-- The actual HTML tree is in "buildinfo/document" -->
|
||||
<xsl:template match="buildinfo/document">
|
||||
<xsl:element name="html">
|
||||
<xsl:attribute name="lang">
|
||||
<xsl:value-of select="/buildinfo/@language" />
|
||||
<xsl:value-of select="/buildinfo/@language"/>
|
||||
</xsl:attribute>
|
||||
<xsl:apply-templates select="node()" />
|
||||
<xsl:apply-templates select="node()"/>
|
||||
</xsl:element>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="body">
|
||||
<body>
|
||||
<xsl:comment>
|
||||
|
||||
DO NOT MODIFY THIS DOCUMENT. IT WAS GENERATED BY XSLT PROCESSING
|
||||
AND YOUR MODIFICATIONS WILL BE LOST. THE SOURCE OF THE DOCUMENT
|
||||
IS IN THE .xml FILE USE make all TO REGENERATE
|
||||
|
||||
</xsl:comment>
|
||||
<table width="100%">
|
||||
<tr>
|
||||
<td>
|
||||
<a href="/"><img alt="[FSFE Logo]" src="/graphics/logo.png" border="0" align="left" /></a>
|
||||
</td>
|
||||
<td class="focus">
|
||||
<table class="focus">
|
||||
<tr>
|
||||
<td colspan="2" class="focus-box">
|
||||
<div align="center">
|
||||
<form action="/cgi-bin/nph-redirect.cgi" method="get">
|
||||
<select name="address" onchange="window.location.href=this.options[this.selectedIndex].value">
|
||||
<option value="#"> - <xsl:value-of select="/buildinfo/textset/text[@id='select']" /> -</option>
|
||||
<option><xsl:attribute name="value">http://www.fsfeurope.org<xsl:value-of select="/buildinfo/@filename" />.<xsl:value-of select="/buildinfo/@language" />.html</xsl:attribute>Global</option>
|
||||
<option><xsl:attribute name="value">http://www.france.fsfeurope.org<xsl:value-of select="/buildinfo/@filename" />.<xsl:value-of select="/buildinfo/@language" />.html</xsl:attribute>France</option>
|
||||
|
||||
<option><xsl:attribute name="value">http://www.germany.fsfeurope.org<xsl:value-of select="/buildinfo/@filename" />.<xsl:value-of select="/buildinfo/@language" />.html</xsl:attribute>Germany</option>
|
||||
<option><xsl:attribute name="value">http://www.italy.fsfeurope.org<xsl:value-of select="/buildinfo/@filename" />.<xsl:value-of select="/buildinfo/@language" />.html</xsl:attribute>Italy</option>
|
||||
<option><xsl:attribute name="value">http://www.spain.fsfeurope.org<xsl:value-of select="/buildinfo/@filename" />.<xsl:value-of select="/buildinfo/@language" />.html</xsl:attribute>Spain</option>
|
||||
<option><xsl:attribute name="value">http://www.sweden.fsfeurope.org<xsl:value-of select="/buildinfo/@filename" />.<xsl:value-of select="/buildinfo/@language" />.html</xsl:attribute>Sweden</option>
|
||||
</select><br /><br />
|
||||
|
||||
<input type="submit" name="submit"><xsl:attribute name="value"><xsl:value-of select="/buildinfo/textset/text[@id='selectgo']" /></xsl:attribute></input>
|
||||
</form>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- <tr>
|
||||
<td class="focus-top-hinge">
|
||||
<xsl:value-of select="/buildinfo/textset/text[@id='find']" />
|
||||
</td>
|
||||
<td class="focus-box">
|
||||
<form method="post" action="/search.cgi">
|
||||
<input type="text" size="10" name="var" />
|
||||
</form>
|
||||
</td>
|
||||
</tr> -->
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="line" colspan="2">
|
||||
<div align="center">
|
||||
<xsl:for-each select="/buildinfo/trlist/tr">
|
||||
<xsl:sort select="@id" />
|
||||
<xsl:choose>
|
||||
<xsl:when test="@id=/buildinfo/@language">
|
||||
<xsl:value-of select="." disable-output-escaping="yes" />
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:element name="a">
|
||||
<xsl:attribute name="href"><xsl:value-of select="/buildinfo/@filename" />.<xsl:value-of select="@id" />.html</xsl:attribute>
|
||||
<xsl:value-of select="." disable-output-escaping="yes" />
|
||||
</xsl:element>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
<xsl:text> </xsl:text>
|
||||
</xsl:for-each>
|
||||
<xsl:if test="/buildinfo/@outdated='yes'"><br />
|
||||
<xsl:apply-templates select="/buildinfo/textset/text[@id='outdated']/node()" />
|
||||
</xsl:if>
|
||||
<xsl:if test="/buildinfo/@language!=/buildinfo/document/@language"><br />
|
||||
<xsl:apply-templates select="/buildinfo/textset/text[@id='notranslation']/node()" />
|
||||
</xsl:if>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="body" valign="top">
|
||||
<xsl:apply-templates select="node()"/>
|
||||
</td>
|
||||
<td class="menu" width="150">
|
||||
<xsl:for-each select="/buildinfo/menuset/menu[not(@parent)]">
|
||||
<xsl:sort select="@id" />
|
||||
<xsl:variable name="id"><xsl:value-of select="@id" /></xsl:variable>
|
||||
<a class="menu" href="{.}">
|
||||
<xsl:value-of select="/buildinfo/textset/text[@id=$id]" />
|
||||
</a> <br />
|
||||
<xsl:for-each select="/buildinfo/menuset/menu[@parent=$id]">
|
||||
<xsl:sort select="@id" />
|
||||
<a class="submenu" href="{.}">
|
||||
<xsl:variable name="mid"><xsl:value-of select="@id" /></xsl:variable>
|
||||
<xsl:value-of select="/buildinfo/textset/text[@id=$mid]" />
|
||||
</a> <br />
|
||||
</xsl:for-each>
|
||||
</xsl:for-each>
|
||||
|
||||
<!-- "Join the Fellowship" button -->
|
||||
<br/>
|
||||
<a href="https://www.fsfe.org/join"><img alt="Join the Fellowship" src="/graphics/global/Join_Fellowship.png" border="0"/></a>
|
||||
<br/>
|
||||
|
||||
<!-- "Donate Today" button >
|
||||
<br/>
|
||||
<a href="/help/paypal.html"><img alt="Donate today" src="/graphics/global/Become_Patron2006_w_small.png" border="0"/></a>
|
||||
<br/-->
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="line" colspan="2">
|
||||
<div align="center">
|
||||
<xsl:apply-templates
|
||||
select="/buildinfo/textset/text[@id='copyright']/node()" />
|
||||
<!-- "Last changed" magic -->
|
||||
<xsl:variable name="timestamp">
|
||||
<xsl:value-of select="/buildinfo/document/timestamp" />
|
||||
</xsl:variable>
|
||||
<!-- FIXME: over time, all pages should have the timestamp -->
|
||||
<!-- tags, so this conditional could be removed -->
|
||||
<xsl:if test="string-length ($timestamp) > 0">
|
||||
<xsl:variable name="Date">
|
||||
<xsl:value-of select="substring-before (substring-after
|
||||
($timestamp, 'Date: '), ' $')" />
|
||||
</xsl:variable>
|
||||
<xsl:variable name="Author">
|
||||
<xsl:value-of select="substring-before (substring-after
|
||||
($timestamp, 'Author: '), ' $')" />
|
||||
</xsl:variable>
|
||||
<xsl:apply-templates
|
||||
select="/buildinfo/textset/text[@id='lastchanged']/node()" />
|
||||
<xsl:value-of select="translate ($Date, '/', '-')" />
|
||||
(<xsl:value-of select="$Author" />)
|
||||
</xsl:if>
|
||||
|
||||
<!-- Link to the XHTML source -->
|
||||
<xsl:element name="a">
|
||||
<xsl:attribute name="href">
|
||||
<xsl:text>/source</xsl:text>
|
||||
<xsl:value-of select="/buildinfo/@filename" />
|
||||
<xsl:text>.</xsl:text>
|
||||
<xsl:value-of select="/buildinfo/document/@language" />
|
||||
<xsl:text>.xhtml</xsl:text>
|
||||
</xsl:attribute>
|
||||
<xsl:text>[XHTML]</xsl:text>
|
||||
</xsl:element>
|
||||
|
||||
<!-- Insert the inofficial translation notice if appropriate -->
|
||||
<xsl:if test="/buildinfo/document/@translation='unofficial'">
|
||||
<xsl:element name="br" />
|
||||
<xsl:value-of select="/buildinfo/textset/text[@id='translator1']" />
|
||||
<xsl:value-of select="/buildinfo/document/translator" />
|
||||
<xsl:value-of select="/buildinfo/textset/text[@id='translator2']" />
|
||||
<xsl:element name="a">
|
||||
<xsl:attribute name="href">
|
||||
<xsl:value-of select="/buildinfo/@filename" />
|
||||
<xsl:text>.en.html</xsl:text>
|
||||
</xsl:attribute>
|
||||
<xsl:value-of select="/buildinfo/textset/text[@id='translator3']" />
|
||||
</xsl:element>
|
||||
<xsl:value-of select="/buildinfo/textset/text[@id='translator4']" />
|
||||
</xsl:if>
|
||||
|
||||
<br />
|
||||
<xsl:apply-templates
|
||||
select="/buildinfo/textset/text[@id='permission']/node()" />
|
||||
|
||||
<br />
|
||||
<xsl:apply-templates
|
||||
select="/buildinfo/textset/text[@id='webmaster']/node()" />
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</xsl:template>
|
||||
|
||||
<!-- HTML head -->
|
||||
<xsl:template match="head">
|
||||
<head>
|
||||
<xsl:copy>
|
||||
<meta name="robots" content="index, follow"/>
|
||||
<link rel="stylesheet" href="/fsfeurope.css" type="text/css" />
|
||||
<link rel="icon" href="/graphics/fsfeurope.ico" type="image/x-icon" />
|
||||
<link rel="shortcut icon" href="/graphics/fsfeurope.ico" type="image/x-icon" />
|
||||
<xsl:apply-templates select="@*|node()"/>
|
||||
</head>
|
||||
</xsl:copy>
|
||||
</xsl:template>
|
||||
|
||||
<xsl:template match="timestamp|translator|buildinfo/set|buildinfo/textset|buildinfo/menuset|buildinfo/trlist" />
|
||||
<!-- HTML body -->
|
||||
<xsl:template match="body">
|
||||
<xsl:copy>
|
||||
|
||||
<!-- First of all, a comment to make clear this is generated -->
|
||||
<xsl:comment>This file was generated by an XSLT script. Please do not edit.</xsl:comment>
|
||||
|
||||
<xsl:comment>Unnecessary <div>, for IE only</xsl:comment>
|
||||
<xsl:element name="div">
|
||||
<xsl:attribute name="class">page</xsl:attribute>
|
||||
|
||||
<xsl:comment>Give non-graphical browsers a way to skip the menu</xsl:comment>
|
||||
<xsl:element name="a">
|
||||
<xsl:attribute name="class">n</xsl:attribute>
|
||||
<xsl:attribute name="id">top</xsl:attribute>
|
||||
<xsl:attribute name="href">#content</xsl:attribute>
|
||||
Skip menu
|
||||
</xsl:element>
|
||||
|
||||
<!-- Menu bar -->
|
||||
<xsl:element name="div">
|
||||
<xsl:attribute name="class">menu</xsl:attribute>
|
||||
|
||||
<!-- Logo -->
|
||||
<xsl:element name="div">
|
||||
<xsl:attribute name="class">logo</xsl:attribute>
|
||||
<xsl:element name="a">
|
||||
<xsl:attribute name="class">gl</xsl:attribute>
|
||||
<xsl:attribute name="href">/</xsl:attribute>
|
||||
<img alt="[FSFE Logo]" src="/graphics/logo.png"/>
|
||||
</xsl:element>
|
||||
</xsl:element>
|
||||
|
||||
<!-- Menu -->
|
||||
<xsl:element name="ul">
|
||||
<xsl:for-each select="/buildinfo/menuset/menu[not(@parent)]">
|
||||
<xsl:sort select="@id"/>
|
||||
<xsl:variable name="id"><xsl:value-of select="@id"/></xsl:variable>
|
||||
<xsl:element name="li">
|
||||
<xsl:element name="a">
|
||||
<xsl:attribute name="href"><xsl:value-of select="{.}"/>
|
||||
<xsl:value-of select="/buildinfo/textset/text[@id=$id]"/>
|
||||
</xsl:element>
|
||||
</xsl:element>
|
||||
<xsl:for-each select="/buildinfo/menuset/menu[@parent=$id]">
|
||||
<xsl:sort select="@id" />
|
||||
<xsl:variable name="mid"><xsl:value-of select="@id"/></xsl:variable>
|
||||
<xsl:element name="li">
|
||||
<xsl:attribute name="class">submenu</xsl:attribute>
|
||||
<xsl:element name="a">
|
||||
<xsl:value-of select="/buildinfo/textset/text[@id=$mid]"/>
|
||||
</xsl:element>
|
||||
</xsl:element>
|
||||
</xsl:for-each>
|
||||
</xsl:for-each>
|
||||
</xsl:element>
|
||||
|
||||
<!-- Focus list -->
|
||||
<xsl:element name="ul">
|
||||
<xsl:variable name="filename"><xsl:value-of select="/buildinfo/@filename"/>.<xsl:value-of select="/buildinfo/@language"/>.html</xsl:variable>
|
||||
<xsl:element name="li">
|
||||
<xsl:element name="a"><xsl:attribute name="href">http://www.fsfeurope.org<xsl:value-of select="$filename"/></xsl:attribute>Our global work</xsl:element>
|
||||
</xsl:element>
|
||||
<xsl:element name="li">
|
||||
<xsl:attribute name="class">submenu</xsl:attribute>
|
||||
<xsl:element name="a"><xsl:attribute name="href">http://www.germany.fsfeurope.org<xsl:value-of select="$filename"/></xsl:attribute>Germany</xsl:element>
|
||||
</xsl:element>
|
||||
<xsl:element name="li">
|
||||
<xsl:attribute name="class">submenu</xsl:attribute>
|
||||
<xsl:element name="a"><xsl:attribute name="href">http://www.italy.fsfeurope.org<xsl:value-of select="$filename"/></xsl:attribute>Italy</xsl:element>
|
||||
</xsl:element>
|
||||
<xsl:element name="li">
|
||||
<xsl:attribute name="class">submenu</xsl:attribute>
|
||||
<xsl:element name="a"><xsl:attribute name="href">http://www.spain.fsfeurope.org<xsl:value-of select="$filename"/></xsl:attribute>Spain</xsl:element>
|
||||
</xsl:element>
|
||||
<xsl:element name="li">
|
||||
<xsl:attribute name="class">submenu</xsl:attribute>
|
||||
<xsl:element name="a"><xsl:attribute name="href">http://www.sweden.fsfeurope.org<xsl:value-of select="$filename"/></xsl:attribute>Sweden</xsl:element>
|
||||
</xsl:element>
|
||||
</xsl:element>
|
||||
|
||||
<!-- Sister organisation list -->
|
||||
<xsl:element name="ul">
|
||||
<xsl:element name="li">Our sister organisations</xsl:element>
|
||||
<xsl:element name="li">
|
||||
<xsl:attribute name="class">submenu</xsl:attribute>
|
||||
<xsl:element name="a"><xsl:attribute name="href">http://www.fsf.org</xsl:attribute>FSF</xsl:element>
|
||||
</xsl:element>
|
||||
<xsl:element name="li">
|
||||
<xsl:attribute name="class">submenu</xsl:attribute>
|
||||
<xsl:element name="a"><xsl:attribute name="href">http://www.fsf.org.in</xsl:attribute>FSF India</xsl:element>
|
||||
<xsl:element name="li">
|
||||
<xsl:attribute name="class">submenu</xsl:attribute>
|
||||
<xsl:element name="a"><xsl:attribute name="href">http://www.fsfla</xsl:attribute>FSF Latin America</xsl:element>
|
||||
</xsl:element>
|
||||
</xsl:element>
|
||||
|
||||
</xsl:element>
|
||||
<!-- End Menu bar -->
|
||||
|
||||
<!-- Language bar -->
|
||||
<xsl:element name="div">
|
||||
<xsl:attribute name="class">language</xsl:attribute>
|
||||
|
||||
<!-- Translation list -->
|
||||
<xsl:element name="ul">
|
||||
<xsl:for-each select="/buildinfo/trlist/tr">
|
||||
<xsl:sort select="@id"/>
|
||||
<xsl:element name="li">
|
||||
<xsl:choose>
|
||||
<xsl:when test="@id=/buildinfo/@language">
|
||||
<xsl:value-of select="." disable-output-escaping="yes"/>
|
||||
</xsl:when>
|
||||
<xsl:otherwise>
|
||||
<xsl:element name="a">
|
||||
<xsl:attribute name="href"><xsl:value-of select="/buildinfo/@filename"/>.<xsl:value-of select="@id"/>.html</xsl:attribute>
|
||||
<xsl:value-of select="." disable-output-escaping="yes"/>
|
||||
</xsl:element>
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:element>
|
||||
</xsl:for-each>
|
||||
</xsl:element>
|
||||
|
||||
<!-- Outdated note -->
|
||||
<xsl:if test="/buildinfo/@outdated='yes'">
|
||||
<xsl:element name="p">
|
||||
<xsl:apply-templates select="/buildinfo/textset/text[@id='outdated']/node()" />
|
||||
</xsl:element>
|
||||
</xsl:if>
|
||||
|
||||
<!-- Missing translation note -->
|
||||
<xsl:if test="/buildinfo/@language!=/buildinfo/document/@language">
|
||||
<xsl:element name="p">
|
||||
<xsl:apply-templates select="/buildinfo/textset/text[@id='notranslation']/node()" />
|
||||
</xsl:element>
|
||||
</xsl:if>
|
||||
|
||||
</xsl:element>
|
||||
<!-- End Language bar -->
|
||||
|
||||
<!-- Content -->
|
||||
<xsl:element name="div">
|
||||
<xsl:attribute name="class">content</xsl:attribute>
|
||||
|
||||
<!-- Here goes the actual content of the <body> node of the input file -->
|
||||
<xsl:apply-templates select="node()"/>
|
||||
|
||||
<!-- Link to top -->
|
||||
<xsl:element name="a">
|
||||
<xsl:attribute name="class">n</xsl:attribute>
|
||||
<xsl:attribute name="href">#top</xsl:attribute>
|
||||
To top
|
||||
</xsl:element>
|
||||
|
||||
</xsl:element>
|
||||
<!-- End Content -->
|
||||
|
||||
<!-- Footer -->
|
||||
<xsl:element name="div">
|
||||
<xsl:attribute name="class">footer</xsl:attribute>
|
||||
|
||||
<xsl:element name="p">
|
||||
|
||||
<!-- Copyright -->
|
||||
<xsl:apply-templates select="/buildinfo/textset/text[@id='copyright']/node()"/>
|
||||
|
||||
<!-- "Last changed" magic -->
|
||||
<xsl:variable name="timestamp">
|
||||
<xsl:value-of select="/buildinfo/document/timestamp"/>
|
||||
</xsl:variable>
|
||||
<!-- FIXME: over time, all pages should have the timestamp -->
|
||||
<!-- tags, so this conditional could be removed -->
|
||||
<xsl:if test="string-length($timestamp) > 0">
|
||||
<xsl:variable name="Date">
|
||||
<xsl:value-of select="substring-before(substring-after($timestamp, 'Date: '), ' $')"/>
|
||||
</xsl:variable>
|
||||
<xsl:variable name="Author">
|
||||
<xsl:value-of select="substring-before(substring-after($timestamp, 'Author: '), ' $')"/>
|
||||
</xsl:variable>
|
||||
<xsl:apply-templates select="/buildinfo/textset/text[@id='lastchanged']/node()"/>
|
||||
<xsl:value-of select="translate ($Date, '/', '-')"/>
|
||||
(<xsl:value-of select="$Author"/>)
|
||||
</xsl:if>
|
||||
|
||||
<!-- Link to the XHTML source -->
|
||||
<xsl:element name="a">
|
||||
<xsl:attribute name="href">
|
||||
<xsl:text>/source</xsl:text>
|
||||
<xsl:value-of select="/buildinfo/@filename"/>
|
||||
<xsl:text>.</xsl:text>
|
||||
<xsl:value-of select="/buildinfo/document/@language"/>
|
||||
<xsl:text>.xhtml</xsl:text>
|
||||
</xsl:attribute>
|
||||
<xsl:text>[XHTML]</xsl:text>
|
||||
</xsl:element>
|
||||
|
||||
<!-- Insert the inofficial translation notice if appropriate -->
|
||||
<xsl:if test="/buildinfo/document/@translation='unofficial'">
|
||||
<xsl:element name="br"/>
|
||||
<xsl:value-of select="/buildinfo/textset/text[@id='translator1']"/>
|
||||
<xsl:value-of select="/buildinfo/document/translator"/>
|
||||
<xsl:value-of select="/buildinfo/textset/text[@id='translator2']"/>
|
||||
<xsl:element name="a">
|
||||
<xsl:attribute name="href">
|
||||
<xsl:value-of select="/buildinfo/@filename"/>
|
||||
<xsl:text>.en.html</xsl:text>
|
||||
</xsl:attribute>
|
||||
<xsl:value-of select="/buildinfo/textset/text[@id='translator3']"/>
|
||||
</xsl:element>
|
||||
<xsl:value-of select="/buildinfo/textset/text[@id='translator4']"/>
|
||||
</xsl:if>
|
||||
|
||||
<!-- Permission note -->
|
||||
<xsl:element name="br"/>
|
||||
<xsl:apply-templates select="/buildinfo/textset/text[@id='permission']/node()"/>
|
||||
|
||||
<!-- Webmaster feedback note -->
|
||||
<xsl:element name="br"/>
|
||||
<xsl:apply-templates select="/buildinfo/textset/text[@id='webmaster']/node()">
|
||||
</xsl:element>
|
||||
|
||||
</xsl:element>
|
||||
<!-- End Footer -->
|
||||
|
||||
</xsl:element>
|
||||
</xsl:copy>
|
||||
</xsl:template>
|
||||
|
||||
<!-- Do not copy non-HTML elements to output -->
|
||||
<xsl:template match="timestamp|translator|buildinfo/set|buildinfo/textset|buildinfo/menuset|buildinfo/trlist"/>
|
||||
|
||||
<!-- For all other nodes, copy verbatim -->
|
||||
<xsl:template match="@*|node()" priority="-1">
|
||||
<xsl:copy>
|
||||
<xsl:apply-templates select="@*|node()"/>
|
||||
</xsl:copy>
|
||||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
|
Loading…
Reference in New Issue
Block a user