mirror of
https://github.com/gmemstr/pogo.git
synced 2024-09-19 17:21:10 +01:00
Changed Url in JSON to point directly to mp3 file
Used for embedding. This affecs the link in the RSS feed as well, although this should not be a big issue.
This commit is contained in:
parent
0ffefbf55e
commit
29db0f76c5
|
@ -12,7 +12,9 @@
|
|||
<div id="podcasts">
|
||||
|
||||
</div>
|
||||
|
||||
<footer>
|
||||
<p>White Rabbit licensed under the GPLv3</p>
|
||||
</footer>
|
||||
<script>
|
||||
get("/json", function(data){
|
||||
json = JSON.parse(data);
|
||||
|
@ -23,7 +25,8 @@ get("/json", function(data){
|
|||
var div = document.createElement('div');
|
||||
div.className = 'podcast';
|
||||
// Todo: Add audio element (must modify feeds fork first!)
|
||||
div.innerHTML = '<h3>'+json.items[i].title+'</h3><p>'+json.items[i].summary+'</p>';
|
||||
div.innerHTML = '<h3>'+json.items[i].title+'</h3><p>'+json.items[i].summary+'</p>'+
|
||||
'<audio controls><source src="'+json.items[i].url+'">';
|
||||
|
||||
var element = document.getElementById("podcasts");
|
||||
element.appendChild(div);
|
||||
|
|
|
@ -1,4 +1,9 @@
|
|||
body {
|
||||
background-color: #f9f9f9;
|
||||
color: #5b9aff;
|
||||
font-family: monospace;
|
||||
}
|
||||
|
||||
.podcast {
|
||||
background-color: white;
|
||||
padding:5%;
|
||||
}
|
|
@ -68,7 +68,7 @@ func generate_rss() {
|
|||
feed.Items = []*feeds.Item{
|
||||
&feeds.Item{
|
||||
Title: title,
|
||||
Link: &feeds.Link{Href: "https://gitgalaxy.com/podcast"},
|
||||
Link: &feeds.Link{Href: "https://podcast.gitgalaxy.com/download/" + file.Name(), Length: "100", Type: "audio/mpeg"},
|
||||
Enclosure: &feeds.Enclosure{Url: "https://podcast.gitgalaxy.com/download/" + file.Name(), Length: "100", Type: "audio/mpeg"},
|
||||
Description: "Hello, World!",
|
||||
Author: &feeds.Author{Name: "Gabriel Simmer", Email: "gabriel@gitgalaxy.com"},
|
||||
|
|
|
@ -1 +0,0 @@
|
|||
hello
|
Loading…
Reference in a new issue