@ -18,39 +18,86 @@
<xsl:include href= "common.xsl" />
<xsl:variable name= "baseurl" > http://www.c3d2.de/</xsl:variable>
<xsl:param name= "selection" select= "''" />
<xsl:template match= "news" >
<rss version= "2.0" >
<xsl:message > selection: '<xsl:value-of select= "$selection" /> '</xsl:message>
<channel >
<title > Pentaradio</title>
<link > <xsl:value-of select= "$baseurl" /> radio.html</link>
<description > C3D2 Podcast</description>
<language > de</language>
<copyright > http://creativecommons.org/licenses/by-sa/2.0/de/</copyright>
<itunes:subtitle > Radio vom CCC Dresden</itunes:subtitle>
<itunes:summary >
Pentaradio sind die Sendungen des Chaos Computer Club Dresden auf coloRadio, bestehend aus einem informativen Rahmenprogramm und Beiträgen zu einem sendungsspezifischen Thema.
</itunes:summary>
<itunes:image href= "{$baseurl}images/pentaradio.png" />
<xsl:choose >
<xsl:when test= "$selection = 'pentaradio'" >
<title > Pentaradio</title>
<link > <xsl:value-of select= "$baseurl" /> radio.html</link>
<description > C3D2 Pentaradio</description>
<language > de</language>
<copyright > http://creativecommons.org/licenses/by-sa/2.0/de/</copyright>
<itunes:subtitle > Radio vom CCC Dresden</itunes:subtitle>
<itunes:summary >
Pentaradio sind die Sendungen des Chaos Computer Club Dresden auf coloRadio, bestehend aus einem informativen Rahmenprogramm und Beiträgen zu einem sendungsspezifischen Thema.
</itunes:summary>
<itunes:image href= "{$baseurl}images/pentaradio.png" />
</xsl:when>
<xsl:when test= "$selection = 'pentacast'" >
<title > Pentacast</title>
<link > <xsl:value-of select= "$baseurl" /> podcast.html</link>
<description > C3D2 Pentacast</description>
<language > de</language>
<copyright > http://creativecommons.org/licenses/by-sa/2.0/de/</copyright>
<itunes:subtitle > Podcasts vom CCC Dresden</itunes:subtitle>
<itunes:summary >
Pentacast sind themenspezifische Sendungen des Chaos
Computer Club Dresden.
</itunes:summary>
<itunes:image href= "{$baseurl}images/pentacast.png" />
</xsl:when>
<xsl:otherwise >
<title > C3D2 Podcast</title>
<link > <xsl:value-of select= "$baseurl" /> </link>
<description > C3D2 Podcast</description>
<language > de</language>
<copyright > http://creativecommons.org/licenses/by-sa/2.0/de/</copyright>
<itunes:subtitle > Radio & Podcasts vom CCC Dresden</itunes:subtitle>
<itunes:summary >
Pentaradio & Pentacast vom Chaos Computer Club Dresden.
</itunes:summary>
<itunes:image href= "{$baseurl}images/pentaradio.png" />
</xsl:otherwise>
</xsl:choose>
<itunes:category text= "Society & culture" />
<itunes:category text= "Talk" >
<itunes:category text= "Radio" />
</itunes:category>
<itunes:category text= "Technology" />
<itunes:author > Chaos Computer Club Dresden</itunes:author>
<xsl:for-each select= "newsfile" >
<xsl:sort select= "date:seconds(document(.)/item/@date)" data-type= "number" order= "descending" />
<!-- xsl:if test="position() <= 10" -->
<xsl:if test= "(starts-with(., ' c o n t e n t / n e w s / p e n t a r a d i o ' ) o r
starts-with(., 'content/news/pentacast')) and
(count(document(.)/item/resource) > 0)">
<xsl:apply-templates select= "document(.)/item/resource" mode= "preselect" >
<xsl:with-param name= "newsfile" select= "." />
</xsl:apply-templates>
</xsl:if>
<xsl:choose >
<xsl:when test= "$selection = 'pentaradio'" >
<xsl:if test= "starts-with(., ' c o n t e n t / n e w s / p e n t a r a d i o ' ) a n d
count(document(.)/item/resource) > 0">
<xsl:apply-templates select= "document(.)/item/resource" mode= "preselect" >
<xsl:with-param name= "newsfile" select= "." />
</xsl:apply-templates>
</xsl:if>
</xsl:when>
<xsl:when test= "$selection = 'pentacast'" >
<xsl:if test= "starts-with(., ' c o n t e n t / n e w s / p e n t a c a s t ' ) a n d
count(document(.)/item/resource) > 0">
<xsl:apply-templates select= "document(.)/item/resource" mode= "preselect" >
<xsl:with-param name= "newsfile" select= "." />
</xsl:apply-templates>
</xsl:if>
</xsl:when>
<xsl:otherwise >
<xsl:if test= "count(document(.)/item/resource) > 0" >
<xsl:apply-templates select= "document(.)/item/resource" mode= "preselect" >
<xsl:with-param name= "newsfile" select= "." />
</xsl:apply-templates>
</xsl:if>
</xsl:otherwise>
</xsl:choose>
</xsl:for-each>
</channel>