YouTube - Version 10.0

Version Description

Download this release

Release Info

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

Code changes from version 9.8 to 10.0

Files changed (4) hide show
  1. images/iconcache.png +0 -0
  2. images/iconcache_gs.png +0 -0
  3. readme.txt +8 -4
  4. youtube.php +245 -70
images/iconcache.png ADDED
Binary file
images/iconcache_gs.png ADDED
Binary file
readme.txt CHANGED
@@ -1,19 +1,19 @@
1
  === YouTube ===
2
  Contributors: embedplus
3
  Plugin Name: YouTube Embed
4
- Tags: youtube snippets, deleted youtube videos, youtube takedowns, blocked youtube videos, youtube impressions, youtube alerts, featured image, css, cross site scripting, accessibility, same origin, screen reader, security, thumbnail, thumbnails, video thumbnails, wordpress security, xss, youtube thumbnails, thumbnail image, origin, lazy load, lazy, load, effects, special effects, get_locale, translator, locale, country code, country, TinyMCE, localization, internationalization, language, multi-language, translate, captions, subtitles, hl, audio, initialize, mute, sound, track, volume, at a glance, channel, annotations, music, music video, songs, song, lyrics, responsive, short code, shortcode, youtube shortcode, diagnostic, youtube status, seo, video seo, rich snippets, reddit, google+, google plus, comments, search, widget, sidebar, responsive, fluid, iphone, mobile, android, tablet, ipad, youtube playlist, playlists, playlist, wmode, hd, autohd, auto hd, video analytics, analytics, google, google analytics, view count, vlog, vlogging, web videos, youtube analytics, youtube, youtube plugin, youtube shortcode, embed youtube, plugin, video, video shortcode, embed videos, youtube player, shortcode, simple, simple youtube, smart youtube playback, youtube embed, wordpress youtube embed, embedding youtube, youtube embedding, video plugin, https, ssl, secure, no-cookie, cookie, html5, youtube html5, multilingual, multi-lingual, l10n, i18n
5
  Requires at least: 3.1
6
  Tested up to: 4.2
7
- Stable tag: 9.8
8
  License: GPLv3 or later
9
 
10
- YouTube embed plugin. Embed responsive YouTube video players and playlists in posts/pages and widgets. Add video thumbnails, analytics, SEO, and more
11
 
12
  == Description ==
13
 
14
  **Here are a few recently added features (even more features below):**
15
 
16
- * Improved accessibility by using title attributes for screen reader support. It should help your site pass functional accessibility evaluations (FAE).
17
  * 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).
18
  * Easy "Insert" button for both the Visual and Text mode of the editor
19
  * [Embed an entire channel as a playlist >>](https://www.youtube.com/watch?v=_9D4yMyd40g)
@@ -28,6 +28,7 @@ YouTube embed plugin. Embed responsive YouTube video players and playlists in po
28
 
29
  You can even extend the plugin with PRO features like:
30
 
 
31
  * [Automatic video thumbnail images](http://embedplus.com/add-youtube-video-thumbnails-featured-image-wordpress.aspx): each post or page that contains at least one video will have the thumbnail of its first video serve as its featured image.
32
  * [Eye-catching special effects for YouTube embeds >>](http://www.embedplus.com/add-special-effects-to-youtube-embeds-in-wordpress.aspx) (uses lazy loading)
33
  * Automatic tagging for video SEO
@@ -138,6 +139,9 @@ You can also start and end each individual video at particular times. Like the a
138
 
139
  == Changelog ==
140
 
 
 
 
141
  = YouTube Embed 9.8 =
142
  Upgraded code to use YouTube API v3.
143
 
1
  === YouTube ===
2
  Contributors: embedplus
3
  Plugin Name: YouTube Embed
4
+ Tags: accessibility, analytics, api, blocked youtube videos, cache, caching, channel, deleted youtube videos, effects, embed youtube, embedding youtube, featured image, get_locale, i18n, internationalization, l10n, language, lazy, lazy load, load, locale, localization, mobile, mute, no-cookie, oembed, page load, page speed, playlist, playlists, plugin, Reddit, responsive, rich snippets, origin, screen reader, secure, security, seo, short code, shortcode, sidebar, special effects, ssl, subtitles, thumbnail, thumbnail image, thumbnails, TinyMCE, translate, translator, video, video analytics, video plugin, video seo, video shortcode, video thumbnails, view count, volume, widget, wordpress security, wordpress youtube embed, xss, youtube, youtube api, youtube analytics, youtube embed, youtube impressions, youtube player, youtube playlist, youtube plugin, youtube shortcode, youtube snippets, youtube takedowns, youtube thumbnails
5
  Requires at least: 3.1
6
  Tested up to: 4.2
7
+ Stable tag: 10.0
8
  License: GPLv3 or later
9
 
10
+ YouTube embed plugin. Embed responsive YouTube video players & playlists in posts & widgets. Add video thumbnails, analytics, SEO, caching...
11
 
12
  == Description ==
13
 
14
  **Here are a few recently added features (even more features below):**
15
 
16
+ * Improved accessibility by using title attributes for screen reader support. It should help your site [pass functional accessibility evaluations (FAE)](https://www.youtube.com/watch?v=gpAiFnYYkbk).
17
  * 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).
18
  * Easy "Insert" button for both the Visual and Text mode of the editor
19
  * [Embed an entire channel as a playlist >>](https://www.youtube.com/watch?v=_9D4yMyd40g)
28
 
29
  You can even extend the plugin with PRO features like:
30
 
31
+ * Caching to avoid making frequent requests to YouTube.com and speed up your page loads.
32
  * [Automatic video thumbnail images](http://embedplus.com/add-youtube-video-thumbnails-featured-image-wordpress.aspx): each post or page that contains at least one video will have the thumbnail of its first video serve as its featured image.
33
  * [Eye-catching special effects for YouTube embeds >>](http://www.embedplus.com/add-special-effects-to-youtube-embeds-in-wordpress.aspx) (uses lazy loading)
34
  * Automatic tagging for video SEO
139
 
140
  == Changelog ==
141
 
142
+ = YouTube Embed 10.0 =
143
+ This update includes improved tips (Free and Pro) and adds caching to the Pro version for faster page loading.
144
+
145
  = YouTube Embed 9.8 =
146
  Upgraded code to use YouTube API v3.
147
 
youtube.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: YouTube
4
  Plugin URI: http://www.embedplus.com/dashboard/pro-easy-video-analytics.aspx
5
  Description: YouTube embed plugin with basic features and convenient defaults. Upgrade now to add tracking, instant video SEO tags, and much more!
6
- Version: 9.8
7
  Author: EmbedPlus Team
8
  Author URI: http://www.embedplus.com
9
  */
@@ -32,7 +32,7 @@
32
  class YouTubePrefs
33
  {
34
 
35
- public static $version = '9.8';
36
  public static $opt_version = 'version';
37
  public static $optembedwidth = null;
38
  public static $optembedheight = null;
@@ -76,6 +76,9 @@ class YouTubePrefs
76
  public static $opt_apikey = 'apikey';
77
  public static $opt_schemaorg = 'schemaorg';
78
  public static $opt_ftpostimg = 'ftpostimg';
 
 
 
79
  public static $opt_dynload = 'dynload';
80
  public static $opt_dyntype = 'dyntype';
81
  public static $opt_alloptions = 'youtubeprefs_alloptions';
@@ -650,6 +653,7 @@ class YouTubePrefs
650
  $_widgetfit = 1;
651
  $_schemaorg = 0;
652
  $_ftpostimg = 0;
 
653
  $_dynload = 0;
654
  $_dyntype = '';
655
  $_wmode = 'opaque';
@@ -699,6 +703,7 @@ class YouTubePrefs
699
  $_widgetfit = self::tryget($arroptions, self::$opt_widgetfit, 1);
700
  $_schemaorg = self::tryget($arroptions, self::$opt_schemaorg, 0);
701
  $_ftpostimg = self::tryget($arroptions, self::$opt_ftpostimg, 0);
 
702
  $_dynload = self::tryget($arroptions, self::$opt_dynload, 0);
703
  $_dyntype = self::tryget($arroptions, self::$opt_dyntype, '');
704
  $_defaultdims = self::tryget($arroptions, self::$opt_defaultdims, 0);
@@ -745,6 +750,7 @@ class YouTubePrefs
745
  self::$opt_widgetfit => $_widgetfit,
746
  self::$opt_schemaorg => $_schemaorg,
747
  self::$opt_ftpostimg => $_ftpostimg,
 
748
  self::$opt_dynload => $_dynload,
749
  self::$opt_dyntype => $_dyntype,
750
  self::$opt_defaultdims => $_defaultdims,
@@ -827,6 +833,8 @@ class YouTubePrefs
827
 
828
  public static function get_html($m, $iscontent)
829
  {
 
 
830
  $link = trim(str_replace(self::$badentities, self::$goodliterals, $m[0]));
831
 
832
  $link = preg_replace('/\s/', '', $link);
@@ -853,6 +861,28 @@ class YouTubePrefs
853
 
854
  $finalparams = $linkparams + self::$alloptions;
855
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
856
  self::init_dimensions($link, $linkparams, $finalparams);
857
 
858
  if (self::$alloptions[self::$opt_nocookie] == 1)
@@ -996,9 +1026,35 @@ class YouTubePrefs
996
  self::$defaultwidth = null;
997
  self::$oembeddata = null;
998
 
 
 
 
 
 
 
 
 
 
999
  return $code;
1000
  }
1001
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1002
  public static function keyvalue($qry, $includev)
1003
  {
1004
  $ytvars = explode('&', $qry);
@@ -1453,6 +1509,30 @@ class YouTubePrefs
1453
  die();
1454
  }
1455
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1456
  public static function custom_admin_pointers_check()
1457
  {
1458
  //return false; // ooopointer shut all off;
@@ -1563,18 +1643,12 @@ class YouTubePrefs
1563
  $new_pointer_content .= '<p>'; // ooopointer
1564
  if (!(self::$alloptions[self::$opt_pro] && strlen(trim(self::$alloptions[self::$opt_pro])) > 0))
1565
  {
1566
- $new_pointer_content .= __('We upgraded the plugin to use the newest version of YouTube&apos;s API, v3. Used in FREE and <a href="' . self::$epbase . '/dashboard/pro-easy-video-analytics.aspx?ref=frompointer" target="_blank">PRO features &raquo;</a>.');
 
1567
  }
1568
  else
1569
  {
1570
- if (self::$alloptions[self::$opt_schemaorg] == 1)
1571
- {
1572
- $new_pointer_content .= 'Important for Pro users: YouTube now requires an API key for SEO tags. Please <a href="' . admin_url('admin.php?page=youtube-my-preferences') . '#ftpostimg">read more here &raquo;</a>';
1573
- }
1574
- else
1575
- {
1576
- $new_pointer_content .= __('We upgraded the plugin to use the newest version of YouTube&apos;s API, v3. Used in FREE and PRO features.');
1577
- }
1578
  }
1579
  $new_pointer_content .= '</p>';
1580
 
@@ -1650,6 +1724,7 @@ class YouTubePrefs
1650
  $new_options[self::$opt_widgetfit] = self::postchecked(self::$opt_widgetfit) ? 1 : 0;
1651
  $new_options[self::$opt_schemaorg] = self::postchecked(self::$opt_schemaorg) ? 1 : 0;
1652
  $new_options[self::$opt_ftpostimg] = self::postchecked(self::$opt_ftpostimg) ? 1 : 0;
 
1653
  $new_options[self::$opt_dynload] = self::postchecked(self::$opt_dynload) ? 1 : 0;
1654
  $new_options[self::$opt_defaultdims] = self::postchecked(self::$opt_defaultdims) ? 1 : 0;
1655
  $new_options[self::$opt_defaultvol] = self::postchecked(self::$opt_defaultvol) ? 1 : 0;
@@ -1727,11 +1802,20 @@ class YouTubePrefs
1727
 
1728
  $all = $new_options + $all;
1729
 
1730
- // Save the posted value in the database
1731
-
1732
  update_option(self::$opt_alloptions, $all);
1733
 
1734
- // Put a settings updated message on the screen
 
 
 
 
 
 
 
 
 
 
 
1735
  ?>
1736
  <div class="updated"><p><strong><?php _e('Settings saved.'); ?></strong></p></div>
1737
  <?php
@@ -1802,7 +1886,7 @@ class YouTubePrefs
1802
  text-decoration: none; background-color: #ffffff;}
1803
  .jumper {height: 25px;}
1804
  .ssschema {float: right; width: 350px; height: auto; margin-right: 10px;}
1805
- .ssfb {float: right; height: auto; margin-right: 10px; margin-left: 15px;}
1806
  .totop {position: absolute; right: 20px; top: 5px; color: #444444; font-size: 10px;}
1807
  input[type=checkbox] {border: 1px solid #000000;}
1808
  .chktitle {display: inline-block; padding: 1px 3px 1px 3px; border-radius: 3px; background-color: #ffffff; border: 1px solid #dddddd;}
@@ -1811,7 +1895,7 @@ class YouTubePrefs
1811
  .pad10 {padding: 10px;}
1812
  #boxdohl {font-weight: bold; padding: 0px 10px; <?php echo $all[self::$opt_dohl] ? '' : 'display: none;' ?>}
1813
  #boxdyn {font-weight: bold; padding: 0px 10px; <?php echo $all[self::$opt_dynload] ? '' : 'display: none;' ?>}
1814
-
1815
  #boxdefaultvol {font-weight: bold; padding: 0px 10px; <?php echo $all[self::$opt_defaultvol] ? '' : 'display: none;' ?>}
1816
  .vol-output {display: none; width: 30px; color: #008800;}
1817
  .vol-range {background-color: #dddddd; border-radius: 3px; cursor: pointer;}
@@ -1826,6 +1910,8 @@ class YouTubePrefs
1826
  .strike {text-decoration: line-through;}
1827
  .upgchecks { padding: 20px; border-radius: 15px; border: 1px dotted #777777; background-color: #fcfcfc; }
1828
  .clearboth {clear: both;}
 
 
1829
  </style>
1830
  <div class="ytindent">
1831
  <br>
@@ -1900,7 +1986,7 @@ class YouTubePrefs
1900
  </p>
1901
  <p class="submit">
1902
  <input type="submit" onclick="return savevalidate();" name="Submit" class="button-primary" value="<?php _e('Save Changes') ?>" />
1903
- <em>If you're using a caching plugin and you do not see your changes after saving, you might want to reset your cache.</em>
1904
  </p>
1905
 
1906
  <div class="ytindent chx">
@@ -2052,6 +2138,41 @@ class YouTubePrefs
2052
  ?>
2053
  <p class="smallnote orange">Below are PRO features for enhanced SEO and performance (works for even past embed links). </p>
2054
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2055
  <p>
2056
  <input name="<?php echo self::$opt_dynload; ?>" id="<?php echo self::$opt_dynload; ?>" <?php checked($all[self::$opt_dynload], 1); ?> type="checkbox" class="checkbox">
2057
  <span id="boxdyn">
@@ -2078,83 +2199,77 @@ class YouTubePrefs
2078
  Add eye-catching special effects that will make your YouTube embeds bounce, flip, pulse, or slide as they load on the screen. Check this box to select your desired effect. <a target="_blank" href="<?php echo self::$epbase ?>/add-special-effects-to-youtube-embeds-in-wordpress.aspx">Read more here &raquo;</a>
2079
  </label>
2080
  </p>
 
2081
  <p>
2082
- <img class="ssfb" src="<?php echo plugins_url('images/youtube_thumbnail_sample.jpg', __FILE__) ?>" />
2083
- <input name="<?php echo self::$opt_ftpostimg; ?>" id="<?php echo self::$opt_ftpostimg; ?>" <?php checked($all[self::$opt_ftpostimg], 1); ?> type="checkbox" class="checkbox">
2084
- <label for="<?php echo self::$opt_ftpostimg; ?>">
2085
- <b>(PRO)</b> <b class="chktitle">Automatic Video Thumbnails: <sup class="orange">NEW</sup></b>
2086
- Automatically grab the thumbnail image of the first video embedded in each post or page, and use it as the featured image. All you have to do is click Update on a post or page and the plugin does the rest!
2087
- (Example shown on the right) <a target="_blank" href="<?php echo self::$epbase ?>/add-youtube-video-thumbnails-featured-image-wordpress.aspx">Read more here &raquo;</a>
2088
- </label>
2089
- </p>
2090
- <div class="clearboth"></div>
2091
- <p>
2092
- <input name="<?php echo self::$opt_schemaorg; ?>" id="<?php echo self::$opt_schemaorg; ?>" <?php checked($all[self::$opt_schemaorg], 1); ?> type="checkbox" class="checkbox">
2093
- <label for="<?php echo self::$opt_schemaorg; ?>">
2094
- <b>(PRO)</b> <b class="chktitle">Video SEO Tags:</b> Update your YouTube embeds with Google, Bing, and Yahoo friendly video SEO markup.
2095
- </label>
2096
- <span id="boxschemaorg">
2097
- <span class="apikey-msg">
2098
- The video SEO tags include data like the title, description, and thumbnail information of each video you embed. This plugin automatically extracts this data directly from YouTube using the version 3 API,
2099
- which will soon replace the version 2 API. This particular API version requires that you obtain an API key so that YouTube can authenticate the requests. Don't worry, it's an easy process.
2100
- Just <a href="https://developers.google.com/youtube/registering_an_application" target="_blank">click this link &raquo;</a> and follow the video to the right to get your API key. Then paste it in the box below, and click the "Save Changes" button:
2101
- <br>
2102
- <span style="vertical-align: middle; display: inline-block;">
2103
- YouTube API Key: <input type="text" name="<?php echo self::$opt_apikey; ?>" id="<?php echo self::$opt_apikey; ?>" value="<?php echo trim($all[self::$opt_apikey]); ?>" class="textinput" style="width: 200px;">
2104
- </span>
2105
- </span>
2106
- <span class="apikey-video">
2107
- <iframe width="384" height="216" src="https://www.youtube.com/embed/2vmBACVETf4?rel=0" frameborder="0" allowfullscreen></iframe>
2108
- </span>
2109
- </span>
2110
- </p>
2111
- <p>
2112
- <br>
2113
  <img class="ssfb" src="<?php echo plugins_url('images/ssfb.jpg', __FILE__) ?>" />
2114
  <input name="<?php echo self::$opt_ogvideo; ?>" id="<?php echo self::$opt_ogvideo; ?>" <?php checked($all[self::$opt_ogvideo], 1); ?> type="checkbox" class="checkbox">
2115
  <label for="<?php echo self::$opt_ogvideo; ?>">
2116
  <b>(PRO)</b> <b class="chktitle">Facebook Open Graph Markup:</b> <span class="pronon">(NEW: PRO Users)</span> Update YouTube embeds on your pages with Open Graph markup to enhance Facebook sharing and discovery of the pages. Your shared pages, for example, will also display embedded video thumbnails on Facebook Timelines.
2117
  </label>
2118
  </p>
 
 
 
 
 
 
 
 
 
 
 
2119
  <?php
2120
  }
2121
  else
2122
  {
2123
  ?>
2124
- <p class="smallnote orange">Below are PRO features for enhanced SEO and performance (works for even past embed links). <a href="<?php echo self::$epbase ?>/dashboard/pro-easy-video-analytics.aspx" target="_blank">Activate them and several other features &raquo;</a></p>
2125
  <p>
2126
  <input disabled type="checkbox" class="checkbox">
2127
  <label>
2128
- <b class="chktitle">Special Loading Effects:</b> <span class="pronon">(PRO Users)</span>
2129
- Add eye-catching special effects that will make your YouTube embeds bounce, flip, pulse, or slide as they load on the screen. Check this box to select your desired effect. <a target="_blank" href="<?php echo self::$epbase ?>/add-special-effects-to-youtube-embeds-in-wordpress.aspx">Read more here &raquo;</a>
2130
  </label>
2131
  </p>
 
 
2132
  <p>
2133
- <img class="ssfb" src="<?php echo plugins_url('images/youtube_thumbnail_sample.jpg', __FILE__) ?>" />
2134
  <input disabled type="checkbox" class="checkbox">
2135
  <label>
2136
- <b class="chktitle">Automatic Video Thumbnails: <sup class="orange">NEW</sup></b> <span class="pronon">(PRO Users)</span>
2137
- Automatically grab the thumbnail image of the first video embedded in each post or page, and use it as the featured image.
2138
- All you have to do is click Update on a post or page and the plugin does the rest!
2139
- (Example shown on the right) <a target="_blank" href="<?php echo self::$epbase ?>/add-youtube-video-thumbnails-featured-image-wordpress.aspx">Read more here &raquo;</a>
2140
  </label>
2141
  </p>
2142
- <div class="clearboth"></div>
2143
  <p>
2144
  <input disabled type="checkbox" class="checkbox">
2145
  <label>
2146
- <b class="chktitle">Video SEO Tags:</b> <span class="pronon">(PRO Users)</span> Update your YouTube embeds with Google, Bing, and Yahoo friendly video SEO markup.
 
2147
  </label>
2148
  </p>
 
2149
  <p>
2150
- <br>
2151
  <img class="ssfb" src="<?php echo plugins_url('images/ssfb.jpg', __FILE__) ?>" />
2152
  <input disabled type="checkbox" class="checkbox">
2153
  <label>
2154
  <b class="chktitle">Facebook Open Graph Markup:</b> <span class="pronon">(NEW: PRO Users)</span> Update YouTube embeds on your pages with Open Graph markup to enhance Facebook sharing and discovery of the pages. Your shared pages, for example, will also display embedded video thumbnails on Facebook Timelines.
2155
  </label>
2156
  </p>
2157
-
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2158
  <?php
2159
  }
2160
  ?>
@@ -2163,7 +2278,7 @@ class YouTubePrefs
2163
  <p class="submit">
2164
  <br>
2165
  <input type="submit" onclick="return savevalidate();" name="Submit" class="button-primary" value="<?php _e('Save Changes') ?>" />
2166
- <em>If you're using a caching plugin and you do not see your changes after saving, you might want to reset your cache.</em>
2167
  </p>
2168
 
2169
  <hr>
@@ -2225,6 +2340,10 @@ class YouTubePrefs
2225
  </h3>
2226
  <div class="procol">
2227
  <ul class="gopro">
 
 
 
 
2228
  <li>
2229
  <img src="<?php echo plugins_url('images/iconwizard.png', __FILE__) ?>">
2230
  Full Visual Embedding Wizard (Easily customize embeds without memorizing codes)
@@ -2249,15 +2368,15 @@ class YouTubePrefs
2249
  <img src="<?php echo plugins_url('images/mobilecompat.png', __FILE__) ?>">
2250
  Check if your embeds have restrictions that can block mobile viewing <sup class="orange bold">NEW</sup>
2251
  </li>
2252
- <li>
2253
- <img src="<?php echo plugins_url('images/videothumbs.png', __FILE__) ?>">
2254
- Automatic video thumbnail images (just click 'Update') <sup class="orange bold">NEW</sup>
2255
- </li>
2256
 
2257
  </ul>
2258
  </div>
2259
  <div class="procol" style="max-width: 465px;">
2260
  <ul class="gopro">
 
 
 
 
2261
  <li>
2262
  <img src="<?php echo plugins_url('images/prioritysupport.png', __FILE__) ?>">
2263
  Priority support (Puts your request in front)
@@ -2284,10 +2403,10 @@ class YouTubePrefs
2284
  <img src="<?php echo plugins_url('images/infinity.png', __FILE__) ?>">
2285
  Unlimited PRO upgrades and downloads
2286
  </li>
2287
- <li>
2288
- <img src="<?php echo plugins_url('images/questionsale.png', __FILE__) ?>">
2289
- What else? You tell us!
2290
- </li>
2291
  </ul>
2292
  </div>
2293
  <div style="clear: both;"></div>
@@ -2336,7 +2455,8 @@ class YouTubePrefs
2336
  <code>[embedyt]http://www.youtube.com/watch?v=ABCDEF&width=400&height=250[/embedyt] [embedyt]http://www.youtube.com/watch?v=GHIJK&width=400&height=250[/embedyt]</code>
2337
  <br> TIP: As shown above, decrease the size of each video so that they fit together on the same line (See the "How To Override Defaults" section for height and width instructions)
2338
  </li>
2339
- <li>Finally, there's a slight chance your custom theme is the issue, if you have one. To know for sure, we suggest temporarily switching to one of the default WordPress themes (e.g., "Twenty Thirteen") just to see if your video does appear. If it suddenly works, then your custom theme is the issue. You can switch back when done testing.</li>
 
2340
  <li>If none of the above work, you can contact us here if you still have issues: ext@embedplus.com. We'll try to respond within a week. PRO users should use the priority form below for faster replies.</li>
2341
  </ul>
2342
  <p>
@@ -2426,6 +2546,9 @@ class YouTubePrefs
2426
  }
2427
  }
2428
 
 
 
 
2429
  // if (jQuery("#<?php echo self::$opt_dohl; ?>").is(":checked"))
2430
  // {
2431
  // if (!(/^[A-Za-z][A-Za-z]$/.test(jQuery.trim(jQuery("#<?php echo self::$opt_hl; ?>").val()))))
@@ -2473,6 +2596,19 @@ class YouTubePrefs
2473
 
2474
  });
2475
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2476
 
2477
  jQuery('#<?php echo self::$opt_nocookie; ?>').change(function()
2478
  {
@@ -2546,6 +2682,44 @@ class YouTubePrefs
2546
  $("input#vol").width(40);
2547
  }
2548
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2549
  jQuery("#showcase-validate").click(function() {
2550
  window.open("<?php echo self::$epbase . "/showcase-validate.aspx?prokey=" . self::$alloptions[self::$opt_pro] ?>" + "&domain=" + mydomain);
2551
  });
@@ -2732,6 +2906,7 @@ class YouTubePrefs
2732
 
2733
  add_action('wp_enqueue_scripts', array('YouTubePrefs', 'ytprefsscript'), 100);
2734
  add_action("wp_ajax_my_embedplus_pro_record", array('YouTubePrefs', 'my_embedplus_pro_record'));
 
2735
  add_action("wp_ajax_my_embedplus_glance_vids", array('YouTubePrefs', 'my_embedplus_glance_vids'));
2736
  add_action("wp_ajax_my_embedplus_glance_count", array('YouTubePrefs', 'my_embedplus_glance_count'));
2737
  add_action("wp_ajax_my_embedplus_dismiss_double_plugin_warning", array('YouTubePrefs', 'my_embedplus_dismiss_double_plugin_warning'));
3
  Plugin Name: YouTube
4
  Plugin URI: http://www.embedplus.com/dashboard/pro-easy-video-analytics.aspx
5
  Description: YouTube embed plugin with basic features and convenient defaults. Upgrade now to add tracking, instant video SEO tags, and much more!
6
+ Version: 10.0
7
  Author: EmbedPlus Team
8
  Author URI: http://www.embedplus.com
9
  */
32
  class YouTubePrefs
33
  {
34
 
35
+ public static $version = '10.0';
36
  public static $opt_version = 'version';
37
  public static $optembedwidth = null;
38
  public static $optembedheight = null;
76
  public static $opt_apikey = 'apikey';
77
  public static $opt_schemaorg = 'schemaorg';
78
  public static $opt_ftpostimg = 'ftpostimg';
79
+ public static $opt_spdc = 'spdc';
80
+ public static $spdcprefix = 'ytpref';
81
+ public static $spdcall = 'youtubeprefs_spdcall';
82
  public static $opt_dynload = 'dynload';
83
  public static $opt_dyntype = 'dyntype';
84
  public static $opt_alloptions = 'youtubeprefs_alloptions';
653
  $_widgetfit = 1;
654
  $_schemaorg = 0;
655
  $_ftpostimg = 0;
656
+ $_spdc = 0;
657
  $_dynload = 0;
658
  $_dyntype = '';
659
  $_wmode = 'opaque';
703
  $_widgetfit = self::tryget($arroptions, self::$opt_widgetfit, 1);
704
  $_schemaorg = self::tryget($arroptions, self::$opt_schemaorg, 0);
705
  $_ftpostimg = self::tryget($arroptions, self::$opt_ftpostimg, 0);
706
+ $_spdc = self::tryget($arroptions, self::$opt_spdc, 0);
707
  $_dynload = self::tryget($arroptions, self::$opt_dynload, 0);
708
  $_dyntype = self::tryget($arroptions, self::$opt_dyntype, '');
709
  $_defaultdims = self::tryget($arroptions, self::$opt_defaultdims, 0);
750
  self::$opt_widgetfit => $_widgetfit,
751
  self::$opt_schemaorg => $_schemaorg,
752
  self::$opt_ftpostimg => $_ftpostimg,
753
+ self::$opt_spdc => $_spdc,
754
  self::$opt_dynload => $_dynload,
755
  self::$opt_dyntype => $_dyntype,
756
  self::$opt_defaultdims => $_defaultdims,
833
 
834
  public static function get_html($m, $iscontent)
835
  {
836
+ //$time_start = microtime(true);
837
+
838
  $link = trim(str_replace(self::$badentities, self::$goodliterals, $m[0]));
839
 
840
  $link = preg_replace('/\s/', '', $link);
861
 
862
  $finalparams = $linkparams + self::$alloptions;
863
 
864
+ $spdckey = '';
865
+ if (self::$alloptions[self::$opt_pro] && strlen(trim(self::$alloptions[self::$opt_pro])) > 0 && self::$alloptions[self::$opt_spdc] == 1)
866
+ {
867
+ try
868
+ {
869
+ $kparams = $finalparams;
870
+ ksort($kparams);
871
+ $jparams = json_encode($kparams);
872
+ $spdckey = self::$spdcprefix . '_' . md5($jparams);
873
+ $spdcval = get_transient($spdckey);
874
+ if (!empty($spdcval))
875
+ {
876
+ //self::debuglog((microtime(true) - $time_start) . "\t" . $spdckey . "\t" . $spdcval . "\r\n");
877
+ return $spdcval;
878
+ }
879
+ }
880
+ catch (Exception $ex)
881
+ {
882
+
883
+ }
884
+ }
885
+
886
  self::init_dimensions($link, $linkparams, $finalparams);
887
 
888
  if (self::$alloptions[self::$opt_nocookie] == 1)
1026
  self::$defaultwidth = null;
1027
  self::$oembeddata = null;
1028
 
1029
+ if (self::$alloptions[self::$opt_pro] && strlen(trim(self::$alloptions[self::$opt_pro])) > 0 && self::$alloptions[self::$opt_spdc] == 1)
1030
+ {
1031
+ set_transient($spdckey, $code, 86400);
1032
+ $allk = get_option(self::$spdcall, array());
1033
+ $allk[] = $spdckey;
1034
+ update_option(self::$spdcall, $allk);
1035
+
1036
+ //self::debuglog((microtime(true) - $time_start) . "\t" . $spdckey . "\t" . $code . "\r\n");
1037
+ }
1038
  return $code;
1039
  }
1040
 
1041
+ public static function debuglog($str)
1042
+ {
1043
+ $handle = fopen(__DIR__ . "\\debug.txt", "a+");
1044
+ fwrite($handle, $str);
1045
+ fclose($handle);
1046
+ }
1047
+
1048
+ public static function spdcpurge()
1049
+ {
1050
+ $allk = get_option(self::$spdcall);
1051
+ foreach ($allk as $t)
1052
+ {
1053
+ $success = delete_transient($t);
1054
+ }
1055
+ update_option(self::$spdcall, array());
1056
+ }
1057
+
1058
  public static function keyvalue($qry, $includev)
1059
  {
1060
  $ytvars = explode('&', $qry);
1509
  die();
1510
  }
1511
 
1512
+ public static function my_embedplus_clearspdc()
1513
+ {
1514
+ $result = array();
1515
+ if (!empty($_SERVER['HTTP_X_REQUESTED_WITH']) && strtolower($_SERVER['HTTP_X_REQUESTED_WITH']) == 'xmlhttprequest')
1516
+ {
1517
+ try
1518
+ {
1519
+ self::spdcpurge();
1520
+ $result['type'] = 'success';
1521
+ }
1522
+ catch (Exception $ex)
1523
+ {
1524
+ $result['type'] = 'error';
1525
+ }
1526
+ echo json_encode($result);
1527
+ }
1528
+ else
1529
+ {
1530
+ $result['type'] = 'error';
1531
+ header("Location: " . $_SERVER["HTTP_REFERER"]);
1532
+ }
1533
+ die();
1534
+ }
1535
+
1536
  public static function custom_admin_pointers_check()
1537
  {
1538
  //return false; // ooopointer shut all off;
1643
  $new_pointer_content .= '<p>'; // ooopointer
1644
  if (!(self::$alloptions[self::$opt_pro] && strlen(trim(self::$alloptions[self::$opt_pro])) > 0))
1645
  {
1646
+
1647
+ $new_pointer_content .= __('This update includes improved tips (Free and Pro) and adds <a href="' . self::$epbase . '/dashboard/pro-easy-video-analytics.aspx?ref=frompointer" target="_blank">caching to the Pro version for faster page loading &raquo;</a>.');
1648
  }
1649
  else
1650
  {
1651
+ $new_pointer_content .= __('This update includes improved tips (Free and Pro) and adds caching to the Pro version for faster page loading.');
 
 
 
 
 
 
 
1652
  }
1653
  $new_pointer_content .= '</p>';
1654
 
1724
  $new_options[self::$opt_widgetfit] = self::postchecked(self::$opt_widgetfit) ? 1 : 0;
1725
  $new_options[self::$opt_schemaorg] = self::postchecked(self::$opt_schemaorg) ? 1 : 0;
1726
  $new_options[self::$opt_ftpostimg] = self::postchecked(self::$opt_ftpostimg) ? 1 : 0;
1727
+ $new_options[self::$opt_spdc] = self::postchecked(self::$opt_spdc) ? 1 : 0;
1728
  $new_options[self::$opt_dynload] = self::postchecked(self::$opt_dynload) ? 1 : 0;
1729
  $new_options[self::$opt_defaultdims] = self::postchecked(self::$opt_defaultdims) ? 1 : 0;
1730
  $new_options[self::$opt_defaultvol] = self::postchecked(self::$opt_defaultvol) ? 1 : 0;
1802
 
1803
  $all = $new_options + $all;
1804
 
 
 
1805
  update_option(self::$opt_alloptions, $all);
1806
 
1807
+ try
1808
+ {
1809
+ self::spdcpurge();
1810
+ if ($all[self::$opt_spdc] == 1)
1811
+ {
1812
+ wp_remote_get(site_url());
1813
+ }
1814
+ }
1815
+ catch (Exception $ex)
1816
+ {
1817
+
1818
+ }
1819
  ?>
1820
  <div class="updated"><p><strong><?php _e('Settings saved.'); ?></strong></p></div>
1821
  <?php
1886
  text-decoration: none; background-color: #ffffff;}
1887
  .jumper {height: 25px;}
1888
  .ssschema {float: right; width: 350px; height: auto; margin-right: 10px;}
1889
+ .ssfb {float: right; height: auto; margin-right: 10px; margin-left: 15px; margin-bottom: 10px;}
1890
  .totop {position: absolute; right: 20px; top: 5px; color: #444444; font-size: 10px;}
1891
  input[type=checkbox] {border: 1px solid #000000;}
1892
  .chktitle {display: inline-block; padding: 1px 3px 1px 3px; border-radius: 3px; background-color: #ffffff; border: 1px solid #dddddd;}
1895
  .pad10 {padding: 10px;}
1896
  #boxdohl {font-weight: bold; padding: 0px 10px; <?php echo $all[self::$opt_dohl] ? '' : 'display: none;' ?>}
1897
  #boxdyn {font-weight: bold; padding: 0px 10px; <?php echo $all[self::$opt_dynload] ? '' : 'display: none;' ?>}
1898
+ #boxspdc {font-weight: bold; padding: 0px 10px; <?php echo $all[self::$opt_spdc] ? '' : 'display: none;' ?>}
1899
  #boxdefaultvol {font-weight: bold; padding: 0px 10px; <?php echo $all[self::$opt_defaultvol] ? '' : 'display: none;' ?>}
1900
  .vol-output {display: none; width: 30px; color: #008800;}
1901
  .vol-range {background-color: #dddddd; border-radius: 3px; cursor: pointer;}
1910
  .strike {text-decoration: line-through;}
1911
  .upgchecks { padding: 20px; border-radius: 15px; border: 1px dotted #777777; background-color: #fcfcfc; }
1912
  .clearboth {clear: both;}
1913
+ div.hr {clear: both; border-bottom: 1px dotted #A8BDD8; margin: 20px 0 20px 0;}
1914
+ .wp-pointer-buttons a.close {margin-top: 0 !important;}
1915
  </style>
1916
  <div class="ytindent">
1917
  <br>
1986
  </p>
1987
  <p class="submit">
1988
  <input type="submit" onclick="return savevalidate();" name="Submit" class="button-primary" value="<?php _e('Save Changes') ?>" />
1989
+ <em>If you're using a separate caching plugin and you do not see your changes after saving, you might want to reset your cache.</em>
1990
  </p>
1991
 
1992
  <div class="ytindent chx">
2138
  ?>
2139
  <p class="smallnote orange">Below are PRO features for enhanced SEO and performance (works for even past embed links). </p>
2140
 
2141
+ <p>
2142
+ <input name="<?php echo self::$opt_spdc; ?>" id="<?php echo self::$opt_spdc; ?>" <?php checked($all[self::$opt_spdc], 1); ?> type="checkbox" class="checkbox">
2143
+ <label for="<?php echo self::$opt_spdc; ?>">
2144
+ <b>(PRO)</b> <b class="chktitle">Faster Page Loads (Caching): <sup class="orange">NEW</sup></b>
2145
+ Use embed caching to speed up your page loads. By default, WordPress needs to request information from YouTube.com's servers for every video you embed, every time a page is loaded. These data requests can add time to your total page load time. Turn on this feature to cache that data (instead of having to request for the same information every time you load a page). This should then make your pages that have videos load faster. It's been noted that even small speed ups in page load can help increase visitor engagement, retention, and conversions.
2146
+ </label>
2147
+ <div id="boxspdc">
2148
+ <input type="button" class="button button-primary" value="Click to clear YouTube cache"/>
2149
+ <span style="display: none;" id="clearspdcloading" class="orange bold">Clearing...</span>
2150
+ <span class="orange bold" style="display: none;" id="clearspdcsuccess">Finished clearing YouTube cache.</span>
2151
+ <span class="orange bold" style="display: none;" id="clearspdcfailed">Sorry, there seemed to be a problem clearing the cache.</span>
2152
+ </div>
2153
+ </p>
2154
+ <div class="hr"></div>
2155
+ <p>
2156
+ <input name="<?php echo self::$opt_schemaorg; ?>" id="<?php echo self::$opt_schemaorg; ?>" <?php checked($all[self::$opt_schemaorg], 1); ?> type="checkbox" class="checkbox">
2157
+ <label for="<?php echo self::$opt_schemaorg; ?>">
2158
+ <b>(PRO)</b> <b class="chktitle">Video SEO Tags:</b> Update your YouTube embeds with Google, Bing, and Yahoo friendly video SEO markup.
2159
+ </label>
2160
+ <span id="boxschemaorg">
2161
+ <span class="apikey-msg">
2162
+ The video SEO tags include data like the title, description, and thumbnail information of each video you embed. This plugin automatically extracts this data directly from YouTube using the version 3 API,
2163
+ which will soon replace the version 2 API. This particular API version requires that you obtain an API key so that YouTube can authenticate the requests. Don't worry, it's an easy process.
2164
+ Just <a href="https://developers.google.com/youtube/registering_an_application" target="_blank">click this link &raquo;</a> and follow the video to the right to get your API key. Then paste it in the box below, and click the "Save Changes" button:
2165
+ <br>
2166
+ <span style="vertical-align: middle; display: inline-block;">
2167
+ YouTube API Key: <input type="text" name="<?php echo self::$opt_apikey; ?>" id="<?php echo self::$opt_apikey; ?>" value="<?php echo trim($all[self::$opt_apikey]); ?>" class="textinput" style="width: 200px;">
2168
+ </span>
2169
+ </span>
2170
+ <span class="apikey-video">
2171
+ <iframe width="384" height="216" src="https://www.youtube.com/embed/2vmBACVETf4?rel=0" frameborder="0" allowfullscreen></iframe>
2172
+ </span>
2173
+ </span>
2174
+ </p>
2175
+ <div class="hr"></div>
2176
  <p>
2177
  <input name="<?php echo self::$opt_dynload; ?>" id="<?php echo self::$opt_dynload; ?>" <?php checked($all[self::$opt_dynload], 1); ?> type="checkbox" class="checkbox">
2178
  <span id="boxdyn">
2199
  Add eye-catching special effects that will make your YouTube embeds bounce, flip, pulse, or slide as they load on the screen. Check this box to select your desired effect. <a target="_blank" href="<?php echo self::$epbase ?>/add-special-effects-to-youtube-embeds-in-wordpress.aspx">Read more here &raquo;</a>
2200
  </label>
2201
  </p>
2202
+ <div class="hr"></div>
2203
  <p>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2204
  <img class="ssfb" src="<?php echo plugins_url('images/ssfb.jpg', __FILE__) ?>" />
2205
  <input name="<?php echo self::$opt_ogvideo; ?>" id="<?php echo self::$opt_ogvideo; ?>" <?php checked($all[self::$opt_ogvideo], 1); ?> type="checkbox" class="checkbox">
2206
  <label for="<?php echo self::$opt_ogvideo; ?>">
2207
  <b>(PRO)</b> <b class="chktitle">Facebook Open Graph Markup:</b> <span class="pronon">(NEW: PRO Users)</span> Update YouTube embeds on your pages with Open Graph markup to enhance Facebook sharing and discovery of the pages. Your shared pages, for example, will also display embedded video thumbnails on Facebook Timelines.
2208
  </label>
2209
  </p>
2210
+ <div class="hr"></div>
2211
+ <p>
2212
+ <img class="ssfb" src="<?php echo plugins_url('images/youtube_thumbnail_sample.jpg', __FILE__) ?>" />
2213
+ <input name="<?php echo self::$opt_ftpostimg; ?>" id="<?php echo self::$opt_ftpostimg; ?>" <?php checked($all[self::$opt_ftpostimg], 1); ?> type="checkbox" class="checkbox">
2214
+ <label for="<?php echo self::$opt_ftpostimg; ?>">
2215
+ <b>(PRO)</b> <b class="chktitle">Automatic Video Thumbnails: <sup class="orange">NEW</sup></b>
2216
+ Automatically grab the thumbnail image of the first video embedded in each post or page, and use it as the featured image. If your theme can display featured images of posts on your blog home, you’ll see the thumbnails there as shown in the picture on the right. All you have to do is click Update on a post or page and the plugin does the rest!
2217
+ (Example shown on the right) <a target="_blank" href="<?php echo self::$epbase ?>/add-youtube-video-thumbnails-featured-image-wordpress.aspx">Watch example here &raquo;</a>
2218
+ </label>
2219
+ </p>
2220
+
2221
  <?php
2222
  }
2223
  else
2224
  {
2225
  ?>
2226
+ <p class="smallnote orange">Below are PRO features for enhanced SEO and performance (works for even past embed links). </p>
2227
  <p>
2228
  <input disabled type="checkbox" class="checkbox">
2229
  <label>
2230
+ <b class="chktitle">Faster Page Loads (Caching): <sup class="orange">NEW</sup></b> <span class="pronon">(PRO Users)</span>
2231
+ Use embed caching to speed up your page loads. By default, WordPress needs to request information from YouTube.com's servers for every video you embed, every time a page is loaded. These data requests can add time to your total page load time. Turn on this feature to cache that data (instead of having to request for the same information every time you load a page). This should then make your pages that have videos load faster. It's been noted that even small speed ups in page load can help increase visitor engagement, retention, and conversions.
2232
  </label>
2233
  </p>
2234
+ <div class="hr"></div>
2235
+
2236
  <p>
 
2237
  <input disabled type="checkbox" class="checkbox">
2238
  <label>
2239
+ <b class="chktitle">Video SEO Tags:</b> <span class="pronon">(PRO Users)</span> Update your YouTube embeds with Google, Bing, and Yahoo friendly video SEO markup.
 
 
 
2240
  </label>
2241
  </p>
2242
+ <div class="hr"></div>
2243
  <p>
2244
  <input disabled type="checkbox" class="checkbox">
2245
  <label>
2246
+ <b class="chktitle">Special Loading Effects:</b> <span class="pronon">(PRO Users)</span>
2247
+ Add eye-catching special effects that will make your YouTube embeds bounce, flip, pulse, or slide as they load on the screen. Check this box to select your desired effect. <a target="_blank" href="<?php echo self::$epbase ?>/add-special-effects-to-youtube-embeds-in-wordpress.aspx">Read more here &raquo;</a>
2248
  </label>
2249
  </p>
2250
+ <div class="hr"></div>
2251
  <p>
 
2252
  <img class="ssfb" src="<?php echo plugins_url('images/ssfb.jpg', __FILE__) ?>" />
2253
  <input disabled type="checkbox" class="checkbox">
2254
  <label>
2255
  <b class="chktitle">Facebook Open Graph Markup:</b> <span class="pronon">(NEW: PRO Users)</span> Update YouTube embeds on your pages with Open Graph markup to enhance Facebook sharing and discovery of the pages. Your shared pages, for example, will also display embedded video thumbnails on Facebook Timelines.
2256
  </label>
2257
  </p>
2258
+ <div class="hr"></div>
2259
+ <p>
2260
+ <img class="ssfb" src="<?php echo plugins_url('images/youtube_thumbnail_sample.jpg', __FILE__) ?>" />
2261
+ <input disabled type="checkbox" class="checkbox">
2262
+ <label>
2263
+ <b class="chktitle">Automatic Video Thumbnails: <sup class="orange">NEW</sup></b> <span class="pronon">(PRO Users)</span>
2264
+ Automatically grab the thumbnail image of the first video embedded in each post or page, and use it as the featured image.
2265
+ All you have to do is click Update on a post or page and the plugin does the rest!
2266
+ (Example shown on the right) <a target="_blank" href="<?php echo self::$epbase ?>/add-youtube-video-thumbnails-featured-image-wordpress.aspx">Read more here &raquo;</a>
2267
+ </label>
2268
+ </p>
2269
+ <div class="hr"></div>
2270
+ <p>
2271
+ <a href="<?php echo self::$epbase ?>/dashboard/pro-easy-video-analytics.aspx" target="_blank">Activate the above and several other features &raquo;</a>
2272
+ </p>
2273
  <?php
2274
  }
2275
  ?>
2278
  <p class="submit">
2279
  <br>
2280
  <input type="submit" onclick="return savevalidate();" name="Submit" class="button-primary" value="<?php _e('Save Changes') ?>" />
2281
+ <em>If you're using a separate caching plugin and you do not see your changes after saving, you might want to reset your cache.</em>
2282
  </p>
2283
 
2284
  <hr>
2340
  </h3>
2341
  <div class="procol">
2342
  <ul class="gopro">
2343
+ <li>
2344
+ <img src="<?php echo plugins_url('images/iconcache.png', __FILE__) ?>">
2345
+ Faster Page Loads (Caching)
2346
+ </li>
2347
  <li>
2348
  <img src="<?php echo plugins_url('images/iconwizard.png', __FILE__) ?>">
2349
  Full Visual Embedding Wizard (Easily customize embeds without memorizing codes)
2368
  <img src="<?php echo plugins_url('images/mobilecompat.png', __FILE__) ?>">
2369
  Check if your embeds have restrictions that can block mobile viewing <sup class="orange bold">NEW</sup>
2370
  </li>
 
 
 
 
2371
 
2372
  </ul>
2373
  </div>
2374
  <div class="procol" style="max-width: 465px;">
2375
  <ul class="gopro">
2376
+ <li>
2377
+ <img src="<?php echo plugins_url('images/videothumbs.png', __FILE__) ?>">
2378
+ Automatic video thumbnail images (just click 'Update') <sup class="orange bold">NEW</sup>
2379
+ </li>
2380
  <li>
2381
  <img src="<?php echo plugins_url('images/prioritysupport.png', __FILE__) ?>">
2382
  Priority support (Puts your request in front)
2403
  <img src="<?php echo plugins_url('images/infinity.png', __FILE__) ?>">
2404
  Unlimited PRO upgrades and downloads
2405
  </li>
2406
+ <!-- <li>
2407
+ <img src="<?php echo plugins_url('images/questionsale.png', __FILE__) ?>">
2408
+ What else? You tell us!
2409
+ </li> -->
2410
  </ul>
2411
  </div>
2412
  <div style="clear: both;"></div>
2455
  <code>[embedyt]http://www.youtube.com/watch?v=ABCDEF&width=400&height=250[/embedyt] [embedyt]http://www.youtube.com/watch?v=GHIJK&width=400&height=250[/embedyt]</code>
2456
  <br> TIP: As shown above, decrease the size of each video so that they fit together on the same line (See the "How To Override Defaults" section for height and width instructions)
2457
  </li>
2458
+ <li>Finally, there's a slight chance your custom theme is the issue, if you have one. To know for sure, we suggest temporarily switching to one of the default WordPress themes (e.g., "Twenty Fourteen") just to see if your video does appear. If it suddenly works, then your custom theme is the issue. You can switch back when done testing.</li>
2459
+ <li>If your videos always appear full size, try turning off "Responsive video sizing."</li>
2460
  <li>If none of the above work, you can contact us here if you still have issues: ext@embedplus.com. We'll try to respond within a week. PRO users should use the priority form below for faster replies.</li>
2461
  </ul>
2462
  <p>
2546
  }
2547
  }
2548
 
2549
+
2550
+
2551
+
2552
  // if (jQuery("#<?php echo self::$opt_dohl; ?>").is(":checked"))
2553
  // {
2554
  // if (!(/^[A-Za-z][A-Za-z]$/.test(jQuery.trim(jQuery("#<?php echo self::$opt_hl; ?>").val()))))
2596
 
2597
  });
2598
 
2599
+ jQuery('#<?php echo self::$opt_spdc; ?>').change(function()
2600
+ {
2601
+ if (jQuery(this).is(":checked"))
2602
+ {
2603
+ jQuery("#boxspdc").show(500);
2604
+ }
2605
+ else
2606
+ {
2607
+ jQuery("#boxspdc").hide(500);
2608
+ }
2609
+ });
2610
+
2611
+
2612
 
2613
  jQuery('#<?php echo self::$opt_nocookie; ?>').change(function()
2614
  {
2682
  $("input#vol").width(40);
2683
  }
2684
 
2685
+
2686
+ jQuery('#boxspdc input').click(function() {
2687
+ jQuery('#clearspdcloading').show();
2688
+ jQuery('#clearspdcfailed').hide();
2689
+ jQuery('#clearspdcsuccess').hide();
2690
+
2691
+ $clearbutton = jQuery(this);
2692
+ $clearbutton.attr('disabled', 'disabled');
2693
+
2694
+ jQuery.ajax({
2695
+ type: "post",
2696
+ dataType: "json",
2697
+ timeout: 30000,
2698
+ url: wpajaxurl,
2699
+ data: {action: 'my_embedplus_clearspdc'},
2700
+ success: function(response) {
2701
+ if (response.type == "success") {
2702
+ jQuery("#clearspdcsuccess").show();
2703
+ }
2704
+ else {
2705
+ jQuery("#clearspdcfailed").show();
2706
+ }
2707
+ },
2708
+ error: function(xhr, ajaxOptions, thrownError) {
2709
+ jQuery("#clearspdcfailed").show();
2710
+ },
2711
+ complete: function() {
2712
+ jQuery('#clearspdcloading').hide();
2713
+ $clearbutton.removeAttr('disabled');
2714
+ }
2715
+
2716
+ });
2717
+
2718
+ });
2719
+
2720
+
2721
+
2722
+
2723
  jQuery("#showcase-validate").click(function() {
2724
  window.open("<?php echo self::$epbase . "/showcase-validate.aspx?prokey=" . self::$alloptions[self::$opt_pro] ?>" + "&domain=" + mydomain);
2725
  });
2906
 
2907
  add_action('wp_enqueue_scripts', array('YouTubePrefs', 'ytprefsscript'), 100);
2908
  add_action("wp_ajax_my_embedplus_pro_record", array('YouTubePrefs', 'my_embedplus_pro_record'));
2909
+ add_action("wp_ajax_my_embedplus_clearspdc", array('YouTubePrefs', 'my_embedplus_clearspdc'));
2910
  add_action("wp_ajax_my_embedplus_glance_vids", array('YouTubePrefs', 'my_embedplus_glance_vids'));
2911
  add_action("wp_ajax_my_embedplus_glance_count", array('YouTubePrefs', 'my_embedplus_glance_count'));
2912
  add_action("wp_ajax_my_embedplus_dismiss_double_plugin_warning", array('YouTubePrefs', 'my_embedplus_dismiss_double_plugin_warning'));