From d39b6e2139b955161d4aae1b9954f666803249f0 Mon Sep 17 00:00:00 2001 From: Bohung Date: Wed, 27 Oct 2021 18:15:17 +0800 Subject: [PATCH] Fix video banner js. --- modules/ad_banner/_ad_banner_widget2_video.html.erb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/modules/ad_banner/_ad_banner_widget2_video.html.erb b/modules/ad_banner/_ad_banner_widget2_video.html.erb index 5406936..cb5ee59 100644 --- a/modules/ad_banner/_ad_banner_widget2_video.html.erb +++ b/modules/ad_banner/_ad_banner_widget2_video.html.erb @@ -73,7 +73,6 @@ if (typeof onYouTubeIframeAPIReady !== 'function'){ delete yt_players[id][k]; }) iframes.each(function(i,iframe){ - console.log($(iframe).attr("id")) var yt_player = yt_players[id][$(iframe).attr("id")]; if(yt_player){ }else{ @@ -122,6 +121,7 @@ if (typeof onYouTubeIframeAPIReady !== 'function'){ } {{extra_state_chnage_script}} } +} $(document).ready(function(){ window.onYouTubePlayerAPIReady = function() { onYouTubeIframeAPIReady.apply(this,arguments); @@ -176,7 +176,6 @@ if (typeof onYouTubeIframeAPIReady !== 'function'){ },300); }) }) -}