From d31be1958de76e5cabc14ddd410287055b6dac0c Mon Sep 17 00:00:00 2001 From: czaks Date: Sat, 20 Jul 2013 18:25:58 -0400 Subject: [PATCH] youtube.js: make it work with thread expand etc. --- js/youtube.js | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/js/youtube.js b/js/youtube.js index ec8c501a..f64d4874 100644 --- a/js/youtube.js +++ b/js/youtube.js @@ -24,12 +24,20 @@ onready(function(){ - $('div.video-container a').click(function() { - var videoID = $(this.parentNode).data('video'); + var do_embed_yt = function(tag) { + $('div.video-container a', tag).click(function() { + var videoID = $(this.parentNode).data('video'); - $(this.parentNode).html('