Crop-Thumbnails - Version 0.10.10

Version Description

  • bugfix: Checks if the current page have a featured image box in the first place
Download this release

Release Info

Developer Volkmar Kantor
Plugin Icon Crop-Thumbnails
Version 0.10.10
Comparing to
See all releases

Code changes from version 0.10.9 to 0.10.10

crop-thumbnails.php CHANGED
@@ -4,7 +4,7 @@
4
  * Plugin URI: http://wordpress.org/extend/plugins/crop-thumbnails/
5
  * Author: Volkmar Kantor
6
  * Author URI: http://www.totalmedial.de
7
- * Version: 0.10.9
8
  * Description: Crop your thumbnails, the easy way.
9
  * Text Domain: crop-thumbnails
10
  *
@@ -27,7 +27,7 @@
27
 
28
  //cpt - stands for crop-post-thumbnail
29
  define('CROP_THUMBS_LANG','cpt_lang');
30
- define('CROP_THUMBS_VERSION','0.10.9');
31
 
32
  function cpt_plugin_init() {
33
  load_plugin_textdomain( CROP_THUMBS_LANG, false, dirname( plugin_basename( __FILE__ ) ) . '/lang/' );
4
  * Plugin URI: http://wordpress.org/extend/plugins/crop-thumbnails/
5
  * Author: Volkmar Kantor
6
  * Author URI: http://www.totalmedial.de
7
+ * Version: 0.10.10
8
  * Description: Crop your thumbnails, the easy way.
9
  * Text Domain: crop-thumbnails
10
  *
27
 
28
  //cpt - stands for crop-post-thumbnail
29
  define('CROP_THUMBS_LANG','cpt_lang');
30
+ define('CROP_THUMBS_VERSION','0.10.10');
31
 
32
  function cpt_plugin_init() {
33
  load_plugin_textdomain( CROP_THUMBS_LANG, false, dirname( plugin_basename( __FILE__ ) ) . '/lang/' );
functions/backendpreparer.php CHANGED
@@ -77,6 +77,10 @@ jQuery(document).ready(function($) {
77
  * add link to featured image box
78
  */
79
  var baseElem = $('#postimagediv');
 
 
 
 
80
  var featuredImageLinkButton = '';
81
  featuredImageLinkButton+= '<p class="cropFeaturedImageWrap hidden">';
82
  featuredImageLinkButton+= '<a class="button cropThumbnailsLink" href="#" data-cropthumbnail=\'{"image_id":'+ parseInt(wp.media.featuredImage.get()) +',"viewmode":"single"}\' title="<?php esc_attr_e('Crop Featured Image',CROP_THUMBS_LANG) ?>">';
77
  * add link to featured image box
78
  */
79
  var baseElem = $('#postimagediv');
80
+ if(!baseElem.length) {
81
+ return;
82
+ }
83
+
84
  var featuredImageLinkButton = '';
85
  featuredImageLinkButton+= '<p class="cropFeaturedImageWrap hidden">';
86
  featuredImageLinkButton+= '<a class="button cropThumbnailsLink" href="#" data-cropthumbnail=\'{"image_id":'+ parseInt(wp.media.featuredImage.get()) +',"viewmode":"single"}\' title="<?php esc_attr_e('Crop Featured Image',CROP_THUMBS_LANG) ?>">';
readme.txt CHANGED
@@ -119,9 +119,12 @@ If you fork and planning to publish the forked plugin, please contact me.
119
  5. Choose what image-sizes should be hidden (for what post-types), for better usability.
120
  6. Quicktest on settings-page, to check if your system is correct setup.
121
 
122
- == Changelog ==
 
 
 
123
  = 0.10.9 =
124
- * bugfix click on the button in the featured image box (WP 4.6 and above)
125
  * button in featured image box is no longer visible if no image is choosed
126
  * minor style improvements
127
 
119
  5. Choose what image-sizes should be hidden (for what post-types), for better usability.
120
  6. Quicktest on settings-page, to check if your system is correct setup.
121
 
122
+ == Changelog ==
123
+ = 0.10.10 =
124
+ * bugfix: Checks if the current page have a featured image box in the first place
125
+
126
  = 0.10.9 =
127
+ * bugfix: click on the button in the featured image box (WP 4.6 and above)
128
  * button in featured image box is no longer visible if no image is choosed
129
  * minor style improvements
130