Video Thumbnails - Version 1.7.3

Version Description

  • More comprehensive search for embedded YouTube videos
Download this release

Release Info

Developer sutherlandboswell
Plugin Icon 128x128 Video Thumbnails
Version 1.7.3
Comparing to
See all releases

Code changes from version 1.7.2 to 1.7.3

Files changed (2) hide show
  1. readme.txt +5 -2
  2. video-thumbnails.php +7 -2
readme.txt CHANGED
@@ -1,10 +1,10 @@
1
  === Video Thumbnails ===
2
  Contributors: sutherlandboswell
3
  Donate link: http://amzn.com/w/1L25YG6FO8AZ1
4
- Tags: Video, Thumbnails, YouTube, Vimeo, Blip.tv, Justin.tv, Dailymotion, Metacafe
5
  Requires at least: 3.0
6
  Tested up to: 3.1
7
- Stable tag: 1.7.2
8
 
9
  Video Thumbnails simplifies the process of automatically displaying video thumbnails in your WordPress template.
10
 
@@ -84,6 +84,9 @@ The Vimeo API has a rate limit, so in rare cases you may exceed this limit. Try
84
 
85
  == Changelog ==
86
 
 
 
 
87
  = 1.7.2 =
88
  * Added support for Dailymotion and Metacafe
89
 
1
  === Video Thumbnails ===
2
  Contributors: sutherlandboswell
3
  Donate link: http://amzn.com/w/1L25YG6FO8AZ1
4
+ Tags: Video, Thumbnails, YouTube, Vimeo, Blip.tv, Justin.tv, Dailymotion, Metacafe, Image, Featured Image, Post Thumbnail
5
  Requires at least: 3.0
6
  Tested up to: 3.1
7
+ Stable tag: 1.7.3
8
 
9
  Video Thumbnails simplifies the process of automatically displaying video thumbnails in your WordPress template.
10
 
84
 
85
  == Changelog ==
86
 
87
+ = 1.7.3 =
88
+ * More comprehensive search for embedded YouTube videos
89
+
90
  = 1.7.2 =
91
  * Added support for Dailymotion and Metacafe
92
 
video-thumbnails.php CHANGED
@@ -5,7 +5,7 @@ Plugin URI: http://sutherlandboswell.com/2010/11/wordpress-video-thumbnails/
5
  Description: Automatically retrieve video thumbnails for your posts and display them in your theme. Currently supports YouTube, Vimeo, Blip.tv, and Justin.tv.
6
  Author: Sutherland Boswell
7
  Author URI: http://sutherlandboswell.com
8
- Version: 1.7.2
9
  License: GPL2
10
  */
11
  /* Copyright 2010 Sutherland Boswell (email : sutherland.boswell@gmail.com)
@@ -109,7 +109,12 @@ function get_video_thumbnail($post_id=null) {
109
 
110
  // Checks for a standard YouTube embed
111
  preg_match('#<object[^>]+>.+?http://www.youtube.com/[ve]/([A-Za-z0-9\-_]+).+?</object>#s', $markup, $matches);
112
-
 
 
 
 
 
113
  // Checks for YouTube iframe
114
  if(!isset($matches[1])) {
115
  preg_match('#http://www.youtube.com/embed/([A-Za-z0-9\-_]+)#s', $markup, $matches);
5
  Description: Automatically retrieve video thumbnails for your posts and display them in your theme. Currently supports YouTube, Vimeo, Blip.tv, and Justin.tv.
6
  Author: Sutherland Boswell
7
  Author URI: http://sutherlandboswell.com
8
+ Version: 1.7.3
9
  License: GPL2
10
  */
11
  /* Copyright 2010 Sutherland Boswell (email : sutherland.boswell@gmail.com)
109
 
110
  // Checks for a standard YouTube embed
111
  preg_match('#<object[^>]+>.+?http://www.youtube.com/[ve]/([A-Za-z0-9\-_]+).+?</object>#s', $markup, $matches);
112
+
113
+ // More comprehensive search for YouTube embed, redundant but necessary until more testing is completed
114
+ if(!isset($matches[1])) {
115
+ preg_match('#http://www.youtube.com/[ve]/([A-Za-z0-9\-_]+)#s', $markup, $matches);
116
+ }
117
+
118
  // Checks for YouTube iframe
119
  if(!isset($matches[1])) {
120
  preg_match('#http://www.youtube.com/embed/([A-Za-z0-9\-_]+)#s', $markup, $matches);