allow campaign banners to contain arbitrary layout
svn path=/branches/test/; revision=33770
This commit is contained in:
parent
d40a279cc4
commit
25e706c5b3
43
index.xsl
43
index.xsl
@ -117,10 +117,18 @@
|
||||
<xsl:template match="campaign" mode="slideshow">
|
||||
<a href="{link}" class="campaign-box">
|
||||
<xsl:attribute name="id"><xsl:value-of select="@id" /></xsl:attribute>
|
||||
|
||||
<!-- If you use the content tag, you can define boxes arbitrarily,
|
||||
but you shouldn't use photo/author/copyright then -->
|
||||
<xsl:if test=" content != '' ">
|
||||
<xsl:apply-templates select="content/@* | content/node()"/>
|
||||
</xsl:if>
|
||||
|
||||
<xsl:if test=" photo != '' "><img src="{photo}" alt="" /></xsl:if>
|
||||
<p class="text">
|
||||
<xsl:value-of select="text" />
|
||||
</p>
|
||||
|
||||
<xsl:if test=" text != '' ">
|
||||
<p class="text"><xsl:value-of select="text" /></p>
|
||||
</xsl:if>
|
||||
|
||||
<!-- Author (if existing) -->
|
||||
<xsl:if test="author != ''">
|
||||
@ -136,37 +144,8 @@
|
||||
|
||||
<!-- display campaign box 4 -->
|
||||
<xsl:template match="campaign-box4">
|
||||
<!--div id="campaign-box-4"-->
|
||||
|
||||
<!--
|
||||
Here are two codes snippets that will provide for a graphical and a text banner.
|
||||
/!\ comment out one of the two, you probably only want one banner on the front page.
|
||||
-->
|
||||
|
||||
<!-- graphical banner -->
|
||||
<!--<a href="/campaigns/ilovefs/ilovefs.html">
|
||||
<img src="/graphics/valentine.png" />
|
||||
</a>-->
|
||||
|
||||
<!--
|
||||
Text banner
|
||||
The ids used here are needed to fetch the correct texts in /tools/texts-content.**.xml
|
||||
/!\ the text with given IDs *must* exist there!
|
||||
-->
|
||||
<!--div class="banner-border">
|
||||
<p>
|
||||
<a href="http://www.defectivebydesign.org/no-drm-in-html5">
|
||||
<xsl:call-template name="gettext">
|
||||
<xsl:with-param name="id" select="'no-drm-in-html5'" />
|
||||
</xsl:call-template>
|
||||
</a>
|
||||
</p>
|
||||
</div -->
|
||||
|
||||
<!--/div-->
|
||||
</xsl:template>
|
||||
|
||||
|
||||
<!--display labels-->
|
||||
|
||||
<!--translated word "newsletter"-->
|
||||
|
@ -1,11 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<campaigns>
|
||||
<campaign running="yes" id="summit16">
|
||||
<!--photo>/graphics/summit2016.jpg</photo-->
|
||||
<text>
|
||||
<link>/community/events/2016/summit/frontpage.en.html</link>
|
||||
<content>
|
||||
<img src="/graphics/fsfe-summit-header-logo.png" align="left" />
|
||||
<img src="/graphics/fsfe-summit-header-date.png" align="right" />
|
||||
</text>
|
||||
<link>/community/events/2016/summit/frontpage.en.html</link>
|
||||
</content>
|
||||
</campaign>
|
||||
</campaigns>
|
||||
|
Loading…
x
Reference in New Issue
Block a user