YouTube - Version 13.1.2.3

Version Description

Download this release

Release Info

Developer embedplus
Plugin Icon 128x128 YouTube
Version 13.1.2.3
Comparing to
See all releases

Code changes from version 13.1.2.2 to 13.1.2.3

includes/vi/vi_admin_menu.php CHANGED
@@ -11,5 +11,5 @@ else if (!(bool) (self::$alloptions[self::$opt_vi_hide_monetize_tab]) || self::v
11
  {
12
  $page_parent = 'youtube-my-preferences';
13
  }
14
- self::$admin_page_hooks[] = add_submenu_page($page_parent, 'Monetize With vi', '<img style="width: 16px; height: 16px; vertical-align: text-top;" src="' . plugins_url(self::$folder_name . '/images/icon-monetize.svg') . '" />&nbsp;&nbsp;Monetize? <sup>new</sup>', 'manage_options', 'youtube-ep-vi', array(get_class(), 'vi_admin_dashboard_pre'));
15
  }
11
  {
12
  $page_parent = 'youtube-my-preferences';
13
  }
14
+ self::$admin_page_hooks[] = add_submenu_page($page_parent, 'Monetize With vi', '<img style="width: 16px; height: 16px; vertical-align: text-top;" src="' . plugins_url(self::$folder_name . '/images/icon-monetize.svg') . '" />&nbsp;&nbsp;Monetize', 'manage_options', 'youtube-ep-vi', array(get_class(), 'vi_admin_dashboard_pre'));
15
  }
readme.txt CHANGED
@@ -4,7 +4,7 @@ Plugin Name: Embed Plus for YouTube - Gallery, Channel, Playlist, Live Stream
4
  Tags: youtube gallery, video gallery, youtube channel, youtube live, live stream
5
  Requires at least: 4.0
6
  Tested up to: 5.3
7
- Stable tag: 13.1.2.2
8
  License: GPLv3 or later
9
 
10
  YouTube Embed WordPress Plugin. Embed a responsive video, YouTube channel gallery, playlist gallery, or YouTube.com live stream (with GDPR options)
@@ -147,6 +147,9 @@ You can also start and end each individual video at particular times. Like the a
147
 
148
  == Changelog ==
149
 
 
 
 
150
  = Embed Plus for YouTube WordPress Plugin 13.1.2.2 =
151
  * Wizard open/close fix
152
  * iOS gallery thumbnail click fix
4
  Tags: youtube gallery, video gallery, youtube channel, youtube live, live stream
5
  Requires at least: 4.0
6
  Tested up to: 5.3
7
+ Stable tag: 13.1.2.3
8
  License: GPLv3 or later
9
 
10
  YouTube Embed WordPress Plugin. Embed a responsive video, YouTube channel gallery, playlist gallery, or YouTube.com live stream (with GDPR options)
147
 
148
  == Changelog ==
149
 
150
+ = Embed Plus for YouTube WordPress Plugin 13.1.2.3 =
151
+ * gallery thumbnail mobile tap/scroll fix
152
+
153
  = Embed Plus for YouTube WordPress Plugin 13.1.2.2 =
154
  * Wizard open/close fix
155
  * iOS gallery thumbnail click fix
scripts/embedplus_mce.css CHANGED
@@ -72,7 +72,6 @@ body #TB_window.epyt-thickbox {
72
  background-origin: padding-box;
73
  background-size: auto;
74
  border-radius: 3px;
75
- border: 1px solid #bbbbbb;
76
  box-sizing: border-box;
77
  /*color: #333;*/
78
  cursor: pointer;
@@ -93,10 +92,7 @@ body #TB_window.epyt-thickbox {
93
 
94
  #dashboard_right_now .page-count a.ytprefs_glance_button:before, #dashboard_right_now .page-count span.ytprefs_glance_button:before
95
  {
96
- content: '';
97
- width: 20px;
98
- height: 20px;
99
- background:transparent url('../images/youtubeicon16off.png') no-repeat scroll 0px 1px;
100
  }
101
 
102
  /* menu button */
72
  background-origin: padding-box;
73
  background-size: auto;
74
  border-radius: 3px;
 
75
  box-sizing: border-box;
76
  /*color: #333;*/
77
  cursor: pointer;
92
 
93
  #dashboard_right_now .page-count a.ytprefs_glance_button:before, #dashboard_right_now .page-count span.ytprefs_glance_button:before
94
  {
95
+ content: "\f236";
 
 
 
96
  }
97
 
98
  /* menu button */
scripts/embedplus_mce.min.css CHANGED
@@ -1,2 +1,2 @@
1
 
2
- .wp_themeSkin span.mce_embedplus_youtubeprefs,span.mce_embedplus_youtubeprefs{background:transparent url("../images/btnprefsoff.png") no-repeat scroll center center!important}.wp_themeSkin span.mce_embedplus_youtubeprefs:hover,span.mce_embedplus_youtubeprefs:hover{background-image:url("../images/btnprefson.png")!important}.wp_themeSkin span.mce_embedplus_youtubeprefs_wiz,span.mce_embedplus_youtubeprefs_wiz{background:transparent url("../images/btnwizoff.png") no-repeat scroll center center!important}.wp_themeSkin span.mce_embedplus_youtubeprefs_wiz:hover,span.mce_embedplus_youtubeprefs_wiz:hover{background-image:url("../images/btnwizon.png")!important}.wp-core-ui a.ytprefs_media_link span,a.ytprefs_media_link span,#media-buttons a.ytprefs_media_link span{background:transparent url("../images/btnwizoff.png") no-repeat scroll top left;display:inline-block;height:16px;margin:2px 2px 0 0;vertical-align:top;width:16px}.wp-core-ui a.ytprefs_media_link:hover span,a.ytprefs_media_link:hover span,#media-buttons a.ytprefs_media_link:hover span{background-image:url("../images/btnwizon.png")}.wp-core-ui a.ytprefs_vi_embed_shortcode span,a.ytprefs_vi_embed_shortcode span,#media-buttons a.ytprefs_vi_embed_shortcode span{background:transparent url("../images/icon-monetize_16x18bw.png") no-repeat scroll top left;display:inline-block;height:16px;margin:4px 2px 0 0;vertical-align:top;width:18px}.wp-core-ui a.ytprefs_vi_embed_shortcode:hover span,a.ytprefs_vi_embed_shortcode:hover span,#media-buttons a.ytprefs_vi_embed_shortcode:hover span{background-image:url("../images/icon-monetize_16x18.png")}body #TB_overlay.epyt-thickbox{z-index:100000000!important}body #TB_window.epyt-thickbox{z-index:100000001!important}#media-buttons a.ytprefs_media_link,.wp-core-ui a.ytprefs_media_link,a.ytprefs_media_link{background-attachment:scroll;background-clip:border-box;background-color:#f3f3f3;background-image:linear-gradient(#fefefe,#f4f4f4);background-origin:padding-box;background-size:auto;border-radius:3px;border:1px solid #bbb;box-sizing:border-box;cursor:pointer;display:inline-block;margin:0 5px 0 0;outline-color:#333;outline-style:none;outline-width:0;padding:0 10px 1px .4em;text-decoration:none;text-shadow:#FFF 0 1px 0;white-space:nowrap}#dashboard_right_now .page-count a.ytprefs_glance_button:before,#dashboard_right_now .page-count span.ytprefs_glance_button:before{content:'';width:20px;height:20px;background:transparent url('../images/youtubeicon16off.png') no-repeat scroll 0 1px}#toplevel_page_youtube-my-preferences>ul>li.wp-first-item{display:none}#wpadminbar #wp-admin-bar-ytprefs-bar-cache>.ab-item:before{content:"\f311";top:2px}
1
 
2
+ .wp_themeSkin span.mce_embedplus_youtubeprefs,span.mce_embedplus_youtubeprefs{background:transparent url("../images/btnprefsoff.png") no-repeat scroll center center!important}.wp_themeSkin span.mce_embedplus_youtubeprefs:hover,span.mce_embedplus_youtubeprefs:hover{background-image:url("../images/btnprefson.png")!important}.wp_themeSkin span.mce_embedplus_youtubeprefs_wiz,span.mce_embedplus_youtubeprefs_wiz{background:transparent url("../images/btnwizoff.png") no-repeat scroll center center!important}.wp_themeSkin span.mce_embedplus_youtubeprefs_wiz:hover,span.mce_embedplus_youtubeprefs_wiz:hover{background-image:url("../images/btnwizon.png")!important}.wp-core-ui a.ytprefs_media_link span,a.ytprefs_media_link span,#media-buttons a.ytprefs_media_link span{background:transparent url("../images/btnwizoff.png") no-repeat scroll top left;display:inline-block;height:16px;margin:2px 2px 0 0;vertical-align:top;width:16px}.wp-core-ui a.ytprefs_media_link:hover span,a.ytprefs_media_link:hover span,#media-buttons a.ytprefs_media_link:hover span{background-image:url("../images/btnwizon.png")}.wp-core-ui a.ytprefs_vi_embed_shortcode span,a.ytprefs_vi_embed_shortcode span,#media-buttons a.ytprefs_vi_embed_shortcode span{background:transparent url("../images/icon-monetize_16x18bw.png") no-repeat scroll top left;display:inline-block;height:16px;margin:4px 2px 0 0;vertical-align:top;width:18px}.wp-core-ui a.ytprefs_vi_embed_shortcode:hover span,a.ytprefs_vi_embed_shortcode:hover span,#media-buttons a.ytprefs_vi_embed_shortcode:hover span{background-image:url("../images/icon-monetize_16x18.png")}body #TB_overlay.epyt-thickbox{z-index:100000000!important}body #TB_window.epyt-thickbox{z-index:100000001!important}#media-buttons a.ytprefs_media_link,.wp-core-ui a.ytprefs_media_link,a.ytprefs_media_link{background-attachment:scroll;background-clip:border-box;background-color:#f3f3f3;background-image:linear-gradient(#fefefe,#f4f4f4);background-origin:padding-box;background-size:auto;border-radius:3px;box-sizing:border-box;cursor:pointer;display:inline-block;margin:0 5px 0 0;outline-color:#333;outline-style:none;outline-width:0;padding:0 10px 1px .4em;text-decoration:none;text-shadow:#FFF 0 1px 0;white-space:nowrap}#dashboard_right_now .page-count a.ytprefs_glance_button:before,#dashboard_right_now .page-count span.ytprefs_glance_button:before{content:"\f236"}#toplevel_page_youtube-my-preferences>ul>li.wp-first-item{display:none}#wpadminbar #wp-admin-bar-ytprefs-bar-cache>.ab-item:before{content:"\f311";top:2px}
scripts/ytprefs.js CHANGED
@@ -15,6 +15,8 @@
15
  ytapi_load: 'light'
16
  };
17
 
 
 
18
  if (window.location.toString().indexOf('https://') === 0)
19
  {
20
  window._EPYT_.ajaxurl = window._EPYT_.ajaxurl.replace("http://", "https://");
@@ -88,7 +90,7 @@
88
  {
89
  event.target.ponce = true;
90
  }
91
-
92
  if (event.data === window.YT.PlayerState.ENDED && $(ifm).data('relstop') == '1' && typeof event.target.stopVideo === 'function')
93
  {
94
  event.target.stopVideo();
@@ -269,6 +271,10 @@
269
  }
270
  $container.on('click touchend', '.epyt-gallery-list .epyt-gallery-thumb', function ()
271
  {
 
 
 
 
272
  $container.find('.epyt-gallery-list .epyt-gallery-thumb').removeClass('epyt-current-video');
273
  $(this).addClass('epyt-current-video');
274
  var vid = $(this).data('videoid');
@@ -307,6 +313,12 @@
307
  window._EPADashboard_.setVidSrc($iframe, vidSrc);
308
  }
309
 
 
 
 
 
 
 
310
  }).on('keydown', '.epyt-gallery-list .epyt-gallery-thumb, .epyt-pagebutton', function (e)
311
  {
312
  var code = e.which;
@@ -330,6 +342,10 @@
330
 
331
  $container.on('click touchend', '.epyt-pagebutton', function ()
332
  {
 
 
 
 
333
  var pageData = {
334
  action: 'my_embedplus_gallery_page',
335
  security: _EPYT_.security,
@@ -389,6 +405,12 @@
389
 
390
  });
391
 
 
 
 
 
 
 
392
  });
393
  }
394
  });
15
  ytapi_load: 'light'
16
  };
17
 
18
+ window._EPYT_.touchmoved = false;
19
+
20
  if (window.location.toString().indexOf('https://') === 0)
21
  {
22
  window._EPYT_.ajaxurl = window._EPYT_.ajaxurl.replace("http://", "https://");
90
  {
91
  event.target.ponce = true;
92
  }
93
+
94
  if (event.data === window.YT.PlayerState.ENDED && $(ifm).data('relstop') == '1' && typeof event.target.stopVideo === 'function')
95
  {
96
  event.target.stopVideo();
271
  }
272
  $container.on('click touchend', '.epyt-gallery-list .epyt-gallery-thumb', function ()
273
  {
274
+ if (window._EPYT_.touchmoved)
275
+ {
276
+ return;
277
+ }
278
  $container.find('.epyt-gallery-list .epyt-gallery-thumb').removeClass('epyt-current-video');
279
  $(this).addClass('epyt-current-video');
280
  var vid = $(this).data('videoid');
313
  window._EPADashboard_.setVidSrc($iframe, vidSrc);
314
  }
315
 
316
+ }).on('touchmove', function (e)
317
+ {
318
+ window._EPYT_.touchmoved = true;
319
+ }).on('touchstart', function ()
320
+ {
321
+ window._EPYT_.touchmoved = false;
322
  }).on('keydown', '.epyt-gallery-list .epyt-gallery-thumb, .epyt-pagebutton', function (e)
323
  {
324
  var code = e.which;
342
 
343
  $container.on('click touchend', '.epyt-pagebutton', function ()
344
  {
345
+ if (window._EPYT_.touchmoved)
346
+ {
347
+ return;
348
+ }
349
  var pageData = {
350
  action: 'my_embedplus_gallery_page',
351
  security: _EPYT_.security,
405
 
406
  });
407
 
408
+ }).on('touchmove', function (e)
409
+ {
410
+ window._EPYT_.touchmoved = true;
411
+ }).on('touchstart', function ()
412
+ {
413
+ window._EPYT_.touchmoved = false;
414
  });
415
  }
416
  });
scripts/ytprefs.min.js CHANGED
@@ -1,2 +1,2 @@
1
 
2
- (function(a,b){a._EPYT_=a._EPYT_||{ajaxurl:"/wp-admin/admin-ajax.php",security:"",gallery_scrolloffset:100,eppathtoscripts:"/wp-content/plugins/youtube-embed-plus/scripts/",eppath:"/wp-content/plugins/youtube-embed-plus/",epresponsiveselector:["iframe.__youtube_prefs_widget__"],epdovol:true,evselector:'iframe.__youtube_prefs__[src], iframe[src*="youtube.com/embed/"], iframe[src*="youtube-nocookie.com/embed/"]',stopMobileBuffer:true,ajax_compat:false,usingdefault:true,ytapi_load:"light"};if(a.location.toString().indexOf("https://")===0){a._EPYT_.ajaxurl=a._EPYT_.ajaxurl.replace("http://","https://")}a._EPYT_.pageLoaded=false;b(a).on("load._EPYT_",function(){a._EPYT_.pageLoaded=true});if(!document.querySelectorAll){document.querySelectorAll=function(d){var f=document,e=f.documentElement.firstChild,c=f.createElement("STYLE");e.appendChild(c);f.__qsaels=[];c.styleSheet.cssText=d+"{x:expression(document.__qsaels.push(this))}";a.scrollBy(0,0);return f.__qsaels}}if(typeof a._EPADashboard_==="undefined"){a._EPADashboard_={initStarted:false,checkCount:0,onPlayerReady:function(f){try{if(typeof _EPYT_.epdovol!=="undefined"&&_EPYT_.epdovol){var d=parseInt(f.target.getIframe().getAttribute("data-vol"));if(!isNaN(d)){if(d===0){f.target.mute()}else{if(f.target.isMuted()){f.target.unMute()}f.target.setVolume(d)}}}var c=parseInt(f.target.getIframe().getAttribute("data-epautoplay"));if(!isNaN(c)&&c===1){f.target.playVideo()}}catch(e){}},onPlayerStateChange:function(f){var e=f.target.getIframe();if(f.data===a.YT.PlayerState.PLAYING&&f.target.ponce!==true&&e.src.indexOf("autoplay=1")===-1){f.target.ponce=true}if(f.data===a.YT.PlayerState.ENDED&&b(e).data("relstop")=="1"&&typeof f.target.stopVideo==="function"){f.target.stopVideo()}var c=b(e).closest(".epyt-gallery");if(!c.length){c=b("#"+b(e).data("epytgalleryid"))}if(c.length){var d=c.find(".epyt-pagebutton").first().data("autonext")=="1";if(d&&f.data===a.YT.PlayerState.ENDED){var g=c.find(".epyt-current-video");if(!g.length){g=c.find(".epyt-gallery-thumb").first()}var h=g.find(" ~ .epyt-gallery-thumb").first();if(h.length){h.click()}else{c.find('.epyt-pagebutton.epyt-next[data-pagetoken!=""][data-pagetoken]').first().click()}}}},justid:function(c){return new RegExp("[\\?&]v=([^&#]*)").exec(c)[1]},setupevents:function(d){if(typeof(a.YT)!=="undefined"&&a.YT!==null&&a.YT.loaded){var c=document.getElementById(d);if(!c.epytsetupdone){a._EPADashboard_.log("Setting up YT API events: "+d);c.epytsetupdone=true;return new a.YT.Player(d,{events:{onReady:a._EPADashboard_.onPlayerReady,onStateChange:a._EPADashboard_.onPlayerStateChange}})}}},apiInit:function(){if(typeof(a.YT)!=="undefined"){a._EPADashboard_.initStarted=true;var c=document.querySelectorAll(_EPYT_.evselector);for(var d=0;d<c.length;d++){if(!c[d].hasAttribute("id")){c[d].id="_dytid_"+Math.round(Math.random()*8999+1000)}a._EPADashboard_.setupevents(c[d].id)}}},log:function(d){try{console.log(d)}catch(c){}},doubleCheck:function(){a._EPADashboard_.checkInterval=setInterval(function(){a._EPADashboard_.checkCount++;if(a._EPADashboard_.checkCount>=5||a._EPADashboard_.initStarted){clearInterval(a._EPADashboard_.checkInterval)}else{a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API init check")}},1000)},selectText:function(e){if(document.selection){var c=document.body.createTextRange();c.moveToElementText(e);c.select()}else{if(a.getSelection){var d=a.getSelection();var c=document.createRange();c.selectNode(e);d.removeAllRanges();d.addRange(c)}}},setVidSrc:function(c,d){c.attr("src",d);c.get(0).epytsetupdone=false;a._EPADashboard_.setupevents(c.attr("id"))},loadYTAPI:function(){if(typeof a.YT==="undefined"){if(a._EPYT_.ytapi_load!=="never"&&(a._EPYT_.ytapi_load==="always"||b('iframe[src*="youtube.com/embed/"]').length)){var c=document.createElement("script");c.src="https://www.youtube.com/iframe_api";c.type="text/javascript";document.getElementsByTagName("head")[0].appendChild(c)}}else{if(a.YT.loaded){if(a._EPYT_.pageLoaded){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API available")}else{b(a).on("load._EPYT_",function(){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API available 2")})}}}},pageReady:function(){b(".epyt-gallery").each(function(){var f=b(this);if(!f.data("epytevents")||!b("body").hasClass("block-editor-page")){f.data("epytevents","1");var e=b(this).find("iframe, div.__youtube_prefs_gdpr__").first();var c=e.attr("src");if(!c){c=e.data("ep-src")}var d=b(this).find(".epyt-gallery-list .epyt-gallery-thumb").first().data("videoid");if(typeof(c)!=="undefined"){c=c.replace(d,"GALLERYVIDEOID");e.data("ep-gallerysrc",c)}else{if(e.hasClass("__youtube_prefs_gdpr__")){e.data("ep-gallerysrc","")}}f.on("click touchend",".epyt-gallery-list .epyt-gallery-thumb",function(){f.find(".epyt-gallery-list .epyt-gallery-thumb").removeClass("epyt-current-video");b(this).addClass("epyt-current-video");var g=b(this).data("videoid");f.data("currvid",g);var k=e.data("ep-gallerysrc").replace("GALLERYVIDEOID",g);var j=f.find(".epyt-pagebutton").first().data("thumbplay");if(j!=="0"&&j!==0){if(k.indexOf("autoplay")>0){k=k.replace("autoplay=0","autoplay=1")}else{k+="&autoplay=1"}e.addClass("epyt-thumbplay")}var h=Math.max(b("body").scrollTop(),b("html").scrollTop());var i=e.offset().top-parseInt(_EPYT_.gallery_scrolloffset);if(h>i){b("html, body").animate({scrollTop:i},500,function(){a._EPADashboard_.setVidSrc(e,k)})}else{a._EPADashboard_.setVidSrc(e,k)}}).on("keydown",".epyt-gallery-list .epyt-gallery-thumb, .epyt-pagebutton",function(h){var g=h.which;if((g===13)||(g===32)){h.preventDefault();b(this).click()}});f.on("mouseenter",".epyt-gallery-list .epyt-gallery-thumb",function(){b(this).addClass("hover")});f.on("mouseleave",".epyt-gallery-list .epyt-gallery-thumb",function(){b(this).removeClass("hover")});f.on("click touchend",".epyt-pagebutton",function(){var i={action:"my_embedplus_gallery_page",security:_EPYT_.security,options:{playlistId:b(this).data("playlistid"),pageToken:b(this).data("pagetoken"),pageSize:b(this).data("pagesize"),columns:b(this).data("epcolumns"),showTitle:b(this).data("showtitle"),showPaging:b(this).data("showpaging"),autonext:b(this).data("autonext"),thumbplay:b(this).data("thumbplay")}};var g=b(this).hasClass("epyt-next");var h=parseInt(f.data("currpage")+"");h+=g?1:-1;f.data("currpage",h);f.find(".epyt-gallery-list").addClass("epyt-loading");b.post(_EPYT_.ajaxurl,i,function(j){f.find(".epyt-gallery-list").html(j);f.find(".epyt-current").each(function(){b(this).text(f.data("currpage"))});f.find('.epyt-gallery-thumb[data-videoid="'+f.data("currvid")+'"]').addClass("epyt-current-video");if(f.find(".epyt-pagebutton").first().data("autonext")=="1"){f.find(".epyt-gallery-thumb").first().click()}}).fail(function(){alert("Sorry, there was an error loading the next page.")}).always(function(){f.find(".epyt-gallery-list").removeClass("epyt-loading");if(f.find(".epyt-pagebutton").first().data("autonext")!="1"){var j=Math.max(b("body").scrollTop(),b("html").scrollTop());var k=f.find(".epyt-gallery-list").offset().top-parseInt(_EPYT_.gallery_scrolloffset);if(j>k){b("html, body").animate({scrollTop:k},500)}}})})}});b("button.__youtube_prefs_gdpr__").on("click",function(c){c.preventDefault();if(b.cookie){b.cookie("ytprefs_gdpr_consent","1",{expires:30,path:"/"});a.top.location.reload()}})}}}a.onYouTubeIframeAPIReady=typeof a.onYouTubeIframeAPIReady!=="undefined"?a.onYouTubeIframeAPIReady:function(){if(a._EPYT_.pageLoaded){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API ready")}else{b(a).on("load._EPYT_",function(){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API ready 2")})}};a._EPADashboard_.loadYTAPI();if(a._EPYT_.pageLoaded){a._EPADashboard_.doubleCheck()}else{b(a).on("load._EPYT_",function(){a._EPADashboard_.doubleCheck()})}b(document).ready(function(){a._EPADashboard_.pageReady();a._EPADashboard_.loadYTAPI();if(a._EPYT_.ajax_compat){b(a).on("load._EPYT_",function(){b(document).ajaxSuccess(function(d,f,c){if(f&&f.responseText&&f.responseText.indexOf("<iframe ")!==-1){a._EPADashboard_.loadYTAPI();a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API AJAX");a._EPADashboard_.pageReady()}})})}})})(window,jQuery);
1
 
2
+ (function(a,b){a._EPYT_=a._EPYT_||{ajaxurl:"/wp-admin/admin-ajax.php",security:"",gallery_scrolloffset:100,eppathtoscripts:"/wp-content/plugins/youtube-embed-plus/scripts/",eppath:"/wp-content/plugins/youtube-embed-plus/",epresponsiveselector:["iframe.__youtube_prefs_widget__"],epdovol:true,evselector:'iframe.__youtube_prefs__[src], iframe[src*="youtube.com/embed/"], iframe[src*="youtube-nocookie.com/embed/"]',stopMobileBuffer:true,ajax_compat:false,usingdefault:true,ytapi_load:"light"};a._EPYT_.touchmoved=false;if(a.location.toString().indexOf("https://")===0){a._EPYT_.ajaxurl=a._EPYT_.ajaxurl.replace("http://","https://")}a._EPYT_.pageLoaded=false;b(a).on("load._EPYT_",function(){a._EPYT_.pageLoaded=true});if(!document.querySelectorAll){document.querySelectorAll=function(d){var f=document,e=f.documentElement.firstChild,c=f.createElement("STYLE");e.appendChild(c);f.__qsaels=[];c.styleSheet.cssText=d+"{x:expression(document.__qsaels.push(this))}";a.scrollBy(0,0);return f.__qsaels}}if(typeof a._EPADashboard_==="undefined"){a._EPADashboard_={initStarted:false,checkCount:0,onPlayerReady:function(f){try{if(typeof _EPYT_.epdovol!=="undefined"&&_EPYT_.epdovol){var d=parseInt(f.target.getIframe().getAttribute("data-vol"));if(!isNaN(d)){if(d===0){f.target.mute()}else{if(f.target.isMuted()){f.target.unMute()}f.target.setVolume(d)}}}var c=parseInt(f.target.getIframe().getAttribute("data-epautoplay"));if(!isNaN(c)&&c===1){f.target.playVideo()}}catch(e){}},onPlayerStateChange:function(f){var e=f.target.getIframe();if(f.data===a.YT.PlayerState.PLAYING&&f.target.ponce!==true&&e.src.indexOf("autoplay=1")===-1){f.target.ponce=true}if(f.data===a.YT.PlayerState.ENDED&&b(e).data("relstop")=="1"&&typeof f.target.stopVideo==="function"){f.target.stopVideo()}var c=b(e).closest(".epyt-gallery");if(!c.length){c=b("#"+b(e).data("epytgalleryid"))}if(c.length){var d=c.find(".epyt-pagebutton").first().data("autonext")=="1";if(d&&f.data===a.YT.PlayerState.ENDED){var g=c.find(".epyt-current-video");if(!g.length){g=c.find(".epyt-gallery-thumb").first()}var h=g.find(" ~ .epyt-gallery-thumb").first();if(h.length){h.click()}else{c.find('.epyt-pagebutton.epyt-next[data-pagetoken!=""][data-pagetoken]').first().click()}}}},justid:function(c){return new RegExp("[\\?&]v=([^&#]*)").exec(c)[1]},setupevents:function(d){if(typeof(a.YT)!=="undefined"&&a.YT!==null&&a.YT.loaded){var c=document.getElementById(d);if(!c.epytsetupdone){a._EPADashboard_.log("Setting up YT API events: "+d);c.epytsetupdone=true;return new a.YT.Player(d,{events:{onReady:a._EPADashboard_.onPlayerReady,onStateChange:a._EPADashboard_.onPlayerStateChange}})}}},apiInit:function(){if(typeof(a.YT)!=="undefined"){a._EPADashboard_.initStarted=true;var c=document.querySelectorAll(_EPYT_.evselector);for(var d=0;d<c.length;d++){if(!c[d].hasAttribute("id")){c[d].id="_dytid_"+Math.round(Math.random()*8999+1000)}a._EPADashboard_.setupevents(c[d].id)}}},log:function(d){try{console.log(d)}catch(c){}},doubleCheck:function(){a._EPADashboard_.checkInterval=setInterval(function(){a._EPADashboard_.checkCount++;if(a._EPADashboard_.checkCount>=5||a._EPADashboard_.initStarted){clearInterval(a._EPADashboard_.checkInterval)}else{a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API init check")}},1000)},selectText:function(e){if(document.selection){var c=document.body.createTextRange();c.moveToElementText(e);c.select()}else{if(a.getSelection){var d=a.getSelection();var c=document.createRange();c.selectNode(e);d.removeAllRanges();d.addRange(c)}}},setVidSrc:function(c,d){c.attr("src",d);c.get(0).epytsetupdone=false;a._EPADashboard_.setupevents(c.attr("id"))},loadYTAPI:function(){if(typeof a.YT==="undefined"){if(a._EPYT_.ytapi_load!=="never"&&(a._EPYT_.ytapi_load==="always"||b('iframe[src*="youtube.com/embed/"]').length)){var c=document.createElement("script");c.src="https://www.youtube.com/iframe_api";c.type="text/javascript";document.getElementsByTagName("head")[0].appendChild(c)}}else{if(a.YT.loaded){if(a._EPYT_.pageLoaded){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API available")}else{b(a).on("load._EPYT_",function(){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API available 2")})}}}},pageReady:function(){b(".epyt-gallery").each(function(){var f=b(this);if(!f.data("epytevents")||!b("body").hasClass("block-editor-page")){f.data("epytevents","1");var e=b(this).find("iframe, div.__youtube_prefs_gdpr__").first();var c=e.attr("src");if(!c){c=e.data("ep-src")}var d=b(this).find(".epyt-gallery-list .epyt-gallery-thumb").first().data("videoid");if(typeof(c)!=="undefined"){c=c.replace(d,"GALLERYVIDEOID");e.data("ep-gallerysrc",c)}else{if(e.hasClass("__youtube_prefs_gdpr__")){e.data("ep-gallerysrc","")}}f.on("click touchend",".epyt-gallery-list .epyt-gallery-thumb",function(){if(a._EPYT_.touchmoved){return}f.find(".epyt-gallery-list .epyt-gallery-thumb").removeClass("epyt-current-video");b(this).addClass("epyt-current-video");var g=b(this).data("videoid");f.data("currvid",g);var k=e.data("ep-gallerysrc").replace("GALLERYVIDEOID",g);var j=f.find(".epyt-pagebutton").first().data("thumbplay");if(j!=="0"&&j!==0){if(k.indexOf("autoplay")>0){k=k.replace("autoplay=0","autoplay=1")}else{k+="&autoplay=1"}e.addClass("epyt-thumbplay")}var h=Math.max(b("body").scrollTop(),b("html").scrollTop());var i=e.offset().top-parseInt(_EPYT_.gallery_scrolloffset);if(h>i){b("html, body").animate({scrollTop:i},500,function(){a._EPADashboard_.setVidSrc(e,k)})}else{a._EPADashboard_.setVidSrc(e,k)}}).on("touchmove",function(g){a._EPYT_.touchmoved=true}).on("touchstart",function(){a._EPYT_.touchmoved=false}).on("keydown",".epyt-gallery-list .epyt-gallery-thumb, .epyt-pagebutton",function(h){var g=h.which;if((g===13)||(g===32)){h.preventDefault();b(this).click()}});f.on("mouseenter",".epyt-gallery-list .epyt-gallery-thumb",function(){b(this).addClass("hover")});f.on("mouseleave",".epyt-gallery-list .epyt-gallery-thumb",function(){b(this).removeClass("hover")});f.on("click touchend",".epyt-pagebutton",function(){if(a._EPYT_.touchmoved){return}var i={action:"my_embedplus_gallery_page",security:_EPYT_.security,options:{playlistId:b(this).data("playlistid"),pageToken:b(this).data("pagetoken"),pageSize:b(this).data("pagesize"),columns:b(this).data("epcolumns"),showTitle:b(this).data("showtitle"),showPaging:b(this).data("showpaging"),autonext:b(this).data("autonext"),thumbplay:b(this).data("thumbplay")}};var g=b(this).hasClass("epyt-next");var h=parseInt(f.data("currpage")+"");h+=g?1:-1;f.data("currpage",h);f.find(".epyt-gallery-list").addClass("epyt-loading");b.post(_EPYT_.ajaxurl,i,function(j){f.find(".epyt-gallery-list").html(j);f.find(".epyt-current").each(function(){b(this).text(f.data("currpage"))});f.find('.epyt-gallery-thumb[data-videoid="'+f.data("currvid")+'"]').addClass("epyt-current-video");if(f.find(".epyt-pagebutton").first().data("autonext")=="1"){f.find(".epyt-gallery-thumb").first().click()}}).fail(function(){alert("Sorry, there was an error loading the next page.")}).always(function(){f.find(".epyt-gallery-list").removeClass("epyt-loading");if(f.find(".epyt-pagebutton").first().data("autonext")!="1"){var j=Math.max(b("body").scrollTop(),b("html").scrollTop());var k=f.find(".epyt-gallery-list").offset().top-parseInt(_EPYT_.gallery_scrolloffset);if(j>k){b("html, body").animate({scrollTop:k},500)}}})}).on("touchmove",function(g){a._EPYT_.touchmoved=true}).on("touchstart",function(){a._EPYT_.touchmoved=false})}});b("button.__youtube_prefs_gdpr__").on("click",function(c){c.preventDefault();if(b.cookie){b.cookie("ytprefs_gdpr_consent","1",{expires:30,path:"/"});a.top.location.reload()}})}}}a.onYouTubeIframeAPIReady=typeof a.onYouTubeIframeAPIReady!=="undefined"?a.onYouTubeIframeAPIReady:function(){if(a._EPYT_.pageLoaded){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API ready")}else{b(a).on("load._EPYT_",function(){a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API ready 2")})}};a._EPADashboard_.loadYTAPI();if(a._EPYT_.pageLoaded){a._EPADashboard_.doubleCheck()}else{b(a).on("load._EPYT_",function(){a._EPADashboard_.doubleCheck()})}b(document).ready(function(){a._EPADashboard_.pageReady();a._EPADashboard_.loadYTAPI();if(a._EPYT_.ajax_compat){b(a).on("load._EPYT_",function(){b(document).ajaxSuccess(function(d,f,c){if(f&&f.responseText&&f.responseText.indexOf("<iframe ")!==-1){a._EPADashboard_.loadYTAPI();a._EPADashboard_.apiInit();a._EPADashboard_.log("YT API AJAX");a._EPADashboard_.pageReady()}})})}})})(window,jQuery);
youtube.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Embed Plus for YouTube - Gallery, Channel, Playlist, Live Stream
4
  Plugin URI: https://www.embedplus.com/dashboard/pro-easy-video-analytics.aspx?ref=plugin
5
  Description: YouTube Embed and YouTube Gallery WordPress Plugin. Embed a responsive video, YouTube channel, playlist gallery, or live stream
6
- Version: 13.1.2.2
7
  Author: Embed Plus for YouTube Team
8
  Author URI: https://www.embedplus.com
9
  */
@@ -34,7 +34,7 @@ class YouTubePrefs
34
 
35
  public static $folder_name = 'youtube-embed-plus';
36
  public static $curltimeout = 30;
37
- public static $version = '13.1.2.2';
38
  public static $opt_version = 'version';
39
  public static $optembedwidth = null;
40
  public static $optembedheight = null;
@@ -277,8 +277,11 @@ class YouTubePrefs
277
 
278
  public static function my_plugin_action_links($links)
279
  {
280
- $links[] = '<a href="' . esc_url(admin_url('admin.php?page=youtube-my-preferences')) . '">Settings</a>';
281
- $links[] = '<a href="https://www.embedplus.com/dashboard/pro-easy-video-analytics.aspx?ref=actionlinks" target="_blank">Pro Version</a>';
 
 
 
282
  return $links;
283
  }
284
 
@@ -288,11 +291,8 @@ class YouTubePrefs
288
  $cnt = self::get_glance_count();
289
 
290
  //display via list
291
- return
292
- '<li class="page-count">
293
- <a href="' . $glancehref . '" class="thickbox ytprefs_glance_button" id="ytprefs_glance_button" title="YouTube Embeds At a Glance">
294
- ' . number_format_i18n($cnt) . ' With YouTube
295
- </a>
296
  </li>';
297
  }
298
 
@@ -2918,7 +2918,7 @@ class YouTubePrefs
2918
  $new_pointer_content = '<h3>' . __('New Update') . '</h3>'; // ooopointer
2919
 
2920
  $new_pointer_content .= '<p>'; // ooopointer
2921
- $new_pointer_content .= "This version fixes urgent wizard and iOS issues for both the Free and <a target=_blank href=" . self::$epbase . '/dashboard/pro-easy-video-analytics.aspx?ref=frompointer' . ">Pro versions &raquo;</a>";
2922
  //$new_pointer_content .= "This version brings back the ability to hide related/suggested videos that show up at the end of YouTube embeds. It also allows monetized sites that are embedding video intelligence (vi) ads to select multiple IAB categories to get more content variety. "
2923
  //. (self::vi_logged_in() ? "<a href=\"" . admin_url('admin.php?page=youtube-ep-vi') . "\">Login here to see &raquo;</a>" : "<a rel=\"#jumpmonetize\" class=\"epyt-jumptab\" href=\"" . admin_url('admin.php?page=youtube-my-preferences#jumpmonetize') . "\">Login here to see &raquo;</a>");
2924
 
@@ -2973,7 +2973,7 @@ class YouTubePrefs
2973
  }
2974
  ?>
2975
  <a class="nav-tab" href="#jumpcompat">Compatibility</a>
2976
- <a class="nav-tab" href="#jumpprivacy">Privacy</a>
2977
  <a class="nav-tab" href="#jumphowto">Embed Manually</a>
2978
  <a class="nav-tab" href="#jumpsupport">Support</a>
2979
  </h3>
@@ -3484,26 +3484,6 @@ class YouTubePrefs
3484
  </p>
3485
 
3486
  <div class="ytindent chx">
3487
- <p>
3488
- <input name="<?php echo self::$opt_restrict_wizard; ?>" id="<?php echo self::$opt_restrict_wizard; ?>" <?php checked($all[self::$opt_restrict_wizard], 1); ?> type="checkbox" class="checkbox">
3489
- <label for="<?php echo self::$opt_restrict_wizard; ?>">
3490
- <b class="chktitle">Restrict Wizard Button:</b> Select which roles can use the YouTube wizard button. For example, you may wish to hide the button from contributors submitting content on the front end.
3491
- </label>
3492
- <br>
3493
- <span id="box_restrict_wizard" class="chx">
3494
- <?php
3495
- foreach (self::$dft_roles as $idx => $role)
3496
- {
3497
- ?>
3498
- <label>
3499
- <input type="checkbox" name="<?php echo self::$opt_restrict_wizard_roles . '[]' ?>" value="<?php echo esc_attr($role) ?>" <?php echo in_array($role, $all[self::$opt_restrict_wizard_roles]) ? 'checked' : '' ?>>
3500
- <?php echo esc_html(ucfirst($role)); ?>s
3501
- </label>
3502
- <?php
3503
- }
3504
- ?>
3505
- </span>
3506
- </p>
3507
  <p>
3508
  <input name="<?php echo self::$opt_glance; ?>" id="<?php echo self::$opt_glance; ?>" <?php checked($all[self::$opt_glance], 1); ?> type="checkbox" class="checkbox">
3509
  <label for="<?php echo self::$opt_glance; ?>"><?php _e('<b class="chktitle">At a glance:</b> Show "At a Glance" Embed Links on the dashboard homepage.') ?></label>
@@ -3590,12 +3570,6 @@ class YouTubePrefs
3590
  <em>Disclaimer: YouTube/Google has issues with this iOS related parameter, but we are providing it here in the event that they support it consistently.</em>
3591
  </label>
3592
  </p>
3593
- <p>
3594
- <input name="<?php echo self::$opt_origin; ?>" id="<?php echo self::$opt_origin; ?>" <?php checked($all[self::$opt_origin], 1); ?> type="checkbox" class="checkbox">
3595
- <label for="<?php echo self::$opt_origin; ?>"><b class="chktitle">Extra Player Security: </b>
3596
- Add site origin information with each embed code as an extra security measure. In YouTube's/Google's own words, checking this option "protects against malicious third-party JavaScript being injected into your page and hijacking control of your YouTube player." We especially recommend checking it as it adds higher security than the built-in YouTube embedding method that comes with the current version of WordPress (i.e. oembed).
3597
- </label>
3598
- </p>
3599
  <p>
3600
  <input name="<?php echo self::$opt_controls; ?>" id="<?php echo self::$opt_controls; ?>" <?php checked($all[self::$opt_controls], 1); ?> type="checkbox" class="checkbox">
3601
  <label for="<?php echo self::$opt_controls; ?>"><b class="chktitle">Show Controls:</b> Show the player's control bar. Unchecking this option creates a cleaner look but limits what your viewers can control (play position, volume, etc.).</label>
@@ -3673,6 +3647,34 @@ class YouTubePrefs
3673
 
3674
  </section>
3675
  <section class="pattern" id="jumpprivacy">
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3676
  <h2>Privacy Options</h2>
3677
  <p>These options may help with privacy restrictions such as GDPR and the EU Cookie Law.</p>
3678
  <div class="ytindent chx">
3
  Plugin Name: Embed Plus for YouTube - Gallery, Channel, Playlist, Live Stream
4
  Plugin URI: https://www.embedplus.com/dashboard/pro-easy-video-analytics.aspx?ref=plugin
5
  Description: YouTube Embed and YouTube Gallery WordPress Plugin. Embed a responsive video, YouTube channel, playlist gallery, or live stream
6
+ Version: 13.1.2.3
7
  Author: Embed Plus for YouTube Team
8
  Author URI: https://www.embedplus.com
9
  */
34
 
35
  public static $folder_name = 'youtube-embed-plus';
36
  public static $curltimeout = 30;
37
+ public static $version = '13.1.2.3';
38
  public static $opt_version = 'version';
39
  public static $optembedwidth = null;
40
  public static $optembedheight = null;
277
 
278
  public static function my_plugin_action_links($links)
279
  {
280
+ if (is_array($links))
281
+ {
282
+ $links[] = '<a href="' . esc_url(admin_url('admin.php?page=youtube-my-preferences')) . '">Settings</a>';
283
+ $links[] = '<a href="https://www.embedplus.com/dashboard/pro-easy-video-analytics.aspx?ref=actionlinks" target="_blank">Pro Version</a>';
284
+ }
285
  return $links;
286
  }
287
 
291
  $cnt = self::get_glance_count();
292
 
293
  //display via list
294
+ return '<li class="page-count">
295
+ <a href="' . $glancehref . '" class="thickbox ytprefs_glance_button" id="ytprefs_glance_button" title="YouTube Embeds At a Glance">' . number_format_i18n($cnt) . ' With YouTube</a>
 
 
 
296
  </li>';
297
  }
298
 
2918
  $new_pointer_content = '<h3>' . __('New Update') . '</h3>'; // ooopointer
2919
 
2920
  $new_pointer_content .= '<p>'; // ooopointer
2921
+ $new_pointer_content .= "This version fixes a gallery scrolling issue for both Free and <a target=_blank href=" . self::$epbase . '/dashboard/pro-easy-video-analytics.aspx?ref=frompointer' . ">Pro versions</a>, and an automatic featured thumbnail issue for <a target=_blank href=" . self::$epbase . '/dashboard/pro-easy-video-analytics.aspx?ref=frompointer' . ">Pro versions</a>.";
2922
  //$new_pointer_content .= "This version brings back the ability to hide related/suggested videos that show up at the end of YouTube embeds. It also allows monetized sites that are embedding video intelligence (vi) ads to select multiple IAB categories to get more content variety. "
2923
  //. (self::vi_logged_in() ? "<a href=\"" . admin_url('admin.php?page=youtube-ep-vi') . "\">Login here to see &raquo;</a>" : "<a rel=\"#jumpmonetize\" class=\"epyt-jumptab\" href=\"" . admin_url('admin.php?page=youtube-my-preferences#jumpmonetize') . "\">Login here to see &raquo;</a>");
2924
 
2973
  }
2974
  ?>
2975
  <a class="nav-tab" href="#jumpcompat">Compatibility</a>
2976
+ <a class="nav-tab" href="#jumpprivacy">Security & Privacy</a>
2977
  <a class="nav-tab" href="#jumphowto">Embed Manually</a>
2978
  <a class="nav-tab" href="#jumpsupport">Support</a>
2979
  </h3>
3484
  </p>
3485
 
3486
  <div class="ytindent chx">
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3487
  <p>
3488
  <input name="<?php echo self::$opt_glance; ?>" id="<?php echo self::$opt_glance; ?>" <?php checked($all[self::$opt_glance], 1); ?> type="checkbox" class="checkbox">
3489
  <label for="<?php echo self::$opt_glance; ?>"><?php _e('<b class="chktitle">At a glance:</b> Show "At a Glance" Embed Links on the dashboard homepage.') ?></label>
3570
  <em>Disclaimer: YouTube/Google has issues with this iOS related parameter, but we are providing it here in the event that they support it consistently.</em>
3571
  </label>
3572
  </p>
 
 
 
 
 
 
3573
  <p>
3574
  <input name="<?php echo self::$opt_controls; ?>" id="<?php echo self::$opt_controls; ?>" <?php checked($all[self::$opt_controls], 1); ?> type="checkbox" class="checkbox">
3575
  <label for="<?php echo self::$opt_controls; ?>"><b class="chktitle">Show Controls:</b> Show the player's control bar. Unchecking this option creates a cleaner look but limits what your viewers can control (play position, volume, etc.).</label>
3647
 
3648
  </section>
3649
  <section class="pattern" id="jumpprivacy">
3650
+ <h2>Security Options</h2>
3651
+ <p>
3652
+ <input name="<?php echo self::$opt_restrict_wizard; ?>" id="<?php echo self::$opt_restrict_wizard; ?>" <?php checked($all[self::$opt_restrict_wizard], 1); ?> type="checkbox" class="checkbox">
3653
+ <label for="<?php echo self::$opt_restrict_wizard; ?>">
3654
+ <b class="chktitle">Restrict Wizard Button:</b> Select which roles can use the YouTube wizard button. For example, you may wish to hide the button from contributors submitting content on the front end.
3655
+ </label>
3656
+ <br>
3657
+ <span id="box_restrict_wizard" class="chx">
3658
+ <?php
3659
+ foreach (self::$dft_roles as $idx => $role)
3660
+ {
3661
+ ?>
3662
+ <label>
3663
+ <input type="checkbox" name="<?php echo self::$opt_restrict_wizard_roles . '[]' ?>" value="<?php echo esc_attr($role) ?>" <?php echo in_array($role, $all[self::$opt_restrict_wizard_roles]) ? 'checked' : '' ?>>
3664
+ <?php echo esc_html(ucfirst($role)); ?>s
3665
+ </label>
3666
+ <?php
3667
+ }
3668
+ ?>
3669
+ </span>
3670
+ </p>
3671
+ <p>
3672
+ <input name="<?php echo self::$opt_origin; ?>" id="<?php echo self::$opt_origin; ?>" <?php checked($all[self::$opt_origin], 1); ?> type="checkbox" class="checkbox">
3673
+ <label for="<?php echo self::$opt_origin; ?>"><b class="chktitle">Extra Player Security: </b>
3674
+ Add site origin information with each embed code as an extra security measure. In YouTube's/Google's own words, checking this option "protects against malicious third-party JavaScript being injected into your page and hijacking control of your YouTube player." We especially recommend checking it as it adds higher security than the built-in YouTube embedding method that comes with the current version of WordPress (i.e. oembed).
3675
+ </label>
3676
+ </p>
3677
+
3678
  <h2>Privacy Options</h2>
3679
  <p>These options may help with privacy restrictions such as GDPR and the EU Cookie Law.</p>
3680
  <div class="ytindent chx">