Multiple Post Thumbnails - Version 1.6.3

Version Description

Download this release

Release Info

Developer chrisscott
Plugin Icon wp plugin Multiple Post Thumbnails
Version 1.6.3
Comparing to
See all releases

Code changes from version 1.6.2 to 1.6.3

Files changed (2) hide show
  1. multi-post-thumbnails.php +3 -3
  2. readme.txt +1 -1
multi-post-thumbnails.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Multiple Post Thumbnails
4
  Plugin URI: http://wordpress.org/extend/plugins/multiple-post-thumbnails/
5
  Description: Adds the ability to add multiple post thumbnails to a post type.
6
- Version: 1.6.2
7
  Author: Chris Scott
8
  Author URI: http://voceplatforms.com/
9
  */
@@ -170,7 +170,7 @@ if (!class_exists('MultiPostThumbnails')) {
170
  * @return void
171
  */
172
  public function enqueue_admin_scripts( $hook ) {
173
- global $wp_version;
174
 
175
  // only load on select pages
176
  if ( ! in_array( $hook, array( 'post-new.php', 'post.php', 'media-upload-popup' ) ) )
@@ -180,7 +180,7 @@ if (!class_exists('MultiPostThumbnails')) {
180
  add_thickbox();
181
  wp_enqueue_script( "mpt-featured-image", $this->plugins_url( 'js/multi-post-thumbnails-admin.js', __FILE__ ), array( 'jquery', 'media-upload' ) );
182
  } else { // 3.5+ media modal
183
- wp_enqueue_media();
184
  wp_enqueue_script( "mpt-featured-image", $this->plugins_url( 'js/multi-post-thumbnails-admin.js', __FILE__ ), array( 'jquery', 'set-post-thumbnail' ) );
185
  wp_enqueue_script( "mpt-featured-image-modal", $this->plugins_url( 'js/media-modal.js', __FILE__ ), array( 'jquery', 'media-models' ) );
186
  }
3
  Plugin Name: Multiple Post Thumbnails
4
  Plugin URI: http://wordpress.org/extend/plugins/multiple-post-thumbnails/
5
  Description: Adds the ability to add multiple post thumbnails to a post type.
6
+ Version: 1.6.3
7
  Author: Chris Scott
8
  Author URI: http://voceplatforms.com/
9
  */
170
  * @return void
171
  */
172
  public function enqueue_admin_scripts( $hook ) {
173
+ global $wp_version, $post_ID;
174
 
175
  // only load on select pages
176
  if ( ! in_array( $hook, array( 'post-new.php', 'post.php', 'media-upload-popup' ) ) )
180
  add_thickbox();
181
  wp_enqueue_script( "mpt-featured-image", $this->plugins_url( 'js/multi-post-thumbnails-admin.js', __FILE__ ), array( 'jquery', 'media-upload' ) );
182
  } else { // 3.5+ media modal
183
+ wp_enqueue_media( array( 'post' => ( $post_ID ? $post_ID : null ) ) );
184
  wp_enqueue_script( "mpt-featured-image", $this->plugins_url( 'js/multi-post-thumbnails-admin.js', __FILE__ ), array( 'jquery', 'set-post-thumbnail' ) );
185
  wp_enqueue_script( "mpt-featured-image-modal", $this->plugins_url( 'js/media-modal.js', __FILE__ ), array( 'jquery', 'media-models' ) );
186
  }
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: chrisscott, voceplatforms
3
  Tags: thumbnails, image, featured image
4
  Requires at least: 2.9.2
5
  Tested up to: 4.0
6
- Stable tag: 1.6.2
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
3
  Tags: thumbnails, image, featured image
4
  Requires at least: 2.9.2
5
  Tested up to: 4.0
6
+ Stable tag: 1.6.3
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9