89 lines
3.7 KiB
XML
89 lines
3.7 KiB
XML
|
<?xml version="1.0" encoding="UTF-8"?>
|
||
|
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd">
|
||
|
<xsl:template match="/">
|
||
|
<html>
|
||
|
<head>
|
||
|
<title><xsl:value-of select="rss/channel/title"/></title>
|
||
|
<style>
|
||
|
body {
|
||
|
font-family: Arial, sans-serif;
|
||
|
max-width: 800px;
|
||
|
margin: 0 auto;
|
||
|
padding: 20px;
|
||
|
line-height: 1.6;
|
||
|
background: #70685d;
|
||
|
}
|
||
|
.header {
|
||
|
text-align: center;
|
||
|
margin-bottom: 40px;
|
||
|
}
|
||
|
.podcast-image {
|
||
|
max-width: 300px;
|
||
|
margin: 20px 0;
|
||
|
}
|
||
|
.episode {
|
||
|
border: 1px solid #ddd;
|
||
|
margin: 20px 0;
|
||
|
padding: 20px;
|
||
|
border-radius: 5px;
|
||
|
}
|
||
|
.episode-title {
|
||
|
color: #333;
|
||
|
font-size: 1.2em;
|
||
|
margin: 0 0 10px 0;
|
||
|
}
|
||
|
.episode-meta {
|
||
|
color: #fff;
|
||
|
font-size: 0.9em;
|
||
|
}
|
||
|
.play-button {
|
||
|
display: inline-block;
|
||
|
background:rgb(20, 83, 46);
|
||
|
color: white;
|
||
|
padding: 5px 15px;
|
||
|
border-radius: 3px;
|
||
|
text-decoration: none;
|
||
|
margin-top: 10px;
|
||
|
}
|
||
|
.play-button:hover {
|
||
|
background:rgb(36, 179, 0);
|
||
|
}
|
||
|
</style>
|
||
|
</head>
|
||
|
<body>
|
||
|
<div class="header">
|
||
|
<h1><xsl:value-of select="rss/channel/title"/></h1>
|
||
|
<img class="podcast-image">
|
||
|
<xsl:attribute name="src">
|
||
|
<xsl:value-of select="rss/channel/itunes:image/@href"/>
|
||
|
</xsl:attribute>
|
||
|
<xsl:attribute name="alt">
|
||
|
<xsl:value-of select="rss/channel/title"/>
|
||
|
</xsl:attribute>
|
||
|
</img>
|
||
|
<p><xsl:value-of select="rss/channel/description"/></p>
|
||
|
<p>Par <xsl:value-of select="rss/channel/itunes:author"/></p>
|
||
|
</div>
|
||
|
|
||
|
<div class="episodes">
|
||
|
<xsl:for-each select="rss/channel/item">
|
||
|
<div class="episode">
|
||
|
<h2 class="episode-title"><xsl:value-of select="title"/></h2>
|
||
|
<div class="episode-meta">
|
||
|
<p>Durée : <xsl:value-of select="itunes:duration"/></p>
|
||
|
<p>Date de publication : <xsl:value-of select="pubDate"/></p>
|
||
|
</div>
|
||
|
<p><xsl:value-of select="description"/></p>
|
||
|
<a class="play-button">
|
||
|
<xsl:attribute name="href">
|
||
|
<xsl:value-of select="enclosure/@url"/>
|
||
|
</xsl:attribute>
|
||
|
Écouter l'épisode
|
||
|
</a>
|
||
|
</div>
|
||
|
</xsl:for-each>
|
||
|
</div>
|
||
|
</body>
|
||
|
</html>
|
||
|
</xsl:template>
|
||
|
</xsl:stylesheet>
|