Display YouTube post

This commit is contained in:
Pierre HUBERT 2019-01-14 18:40:28 +01:00
parent 30a96d56ec
commit 3da2455945

View File

@ -216,6 +216,7 @@ function ApplyPosts(){
//Process different kind of posts
//Post with image
if(post.kind == "image") {
var image = createElem2({
@ -227,6 +228,19 @@ function ApplyPosts(){
}
//Post with YouTube video
if(post.kind == "youtube"){
let youtube_link = "https://www.youtube.com/watch?v=" + post.file_path;
createElem2({
appendTo: cardContent,
type: "p",
innerHTML: "Target Video : <a href='" + youtube_link + "' target='_blank'>" + youtube_link + "</a>"
});
}
//Display the list of comments
let postComments = createElem2({