Version Description
- fix warning: when settings are saved
Download this release
Release Info
Developer | Volkmar Kantor |
Plugin | Crop-Thumbnails |
Version | 0.8.1 |
Comparing to | |
See all releases |
Code changes from version 0.8.0 to 0.8.1
- crop-thumbnails.php +1 -1
- functions/settings.php +14 -9
- readme.txt +3 -0
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.8.
|
8 |
* Description: Crop your thumbnails, the easy way.
|
9 |
*
|
10 |
* License: GPL v3
|
4 |
* Plugin URI: http://wordpress.org/extend/plugins/crop-thumbnails/
|
5 |
* Author: Volkmar Kantor
|
6 |
* Author URI: http://www.totalmedial.de
|
7 |
+
* Version: 0.8.1
|
8 |
* Description: Crop your thumbnails, the easy way.
|
9 |
*
|
10 |
* License: GPL v3
|
functions/settings.php
CHANGED
@@ -171,21 +171,26 @@ class CropThumbnailsSettings {
|
|
171 |
$sizes = $this->getImageSizes();
|
172 |
|
173 |
$post_types = $this->getPostTypes();
|
174 |
-
|
175 |
$storeInDb = array();
|
176 |
//check input[hide_post_type] --> are the post_types real there
|
177 |
-
|
178 |
-
|
179 |
-
$
|
|
|
|
|
180 |
}
|
181 |
}
|
182 |
|
|
|
183 |
//check $input[sizes] --> are post_types correct, are sizes real there
|
184 |
-
|
185 |
-
|
186 |
-
|
187 |
-
|
188 |
-
$
|
|
|
|
|
189 |
}
|
190 |
}
|
191 |
}
|
171 |
$sizes = $this->getImageSizes();
|
172 |
|
173 |
$post_types = $this->getPostTypes();
|
174 |
+
|
175 |
$storeInDb = array();
|
176 |
//check input[hide_post_type] --> are the post_types real there
|
177 |
+
if(!empty($input['hide_post_type'])) {
|
178 |
+
foreach($input['hide_post_type'] as $_post_type_name=>$value) {
|
179 |
+
if(isset($post_types[$_post_type_name])) {
|
180 |
+
$storeInDb['hide_post_type'][$_post_type_name] = '1';
|
181 |
+
}
|
182 |
}
|
183 |
}
|
184 |
|
185 |
+
|
186 |
//check $input[sizes] --> are post_types correct, are sizes real there
|
187 |
+
if(!empty($input['hide_size'])) {
|
188 |
+
foreach($input['hide_size'] as $_post_type_name=>$size_type) {
|
189 |
+
if(isset($post_types[$_post_type_name])) {
|
190 |
+
foreach($size_type as $_size_name=>$value) {
|
191 |
+
if(isset($sizes[$_size_name])) {
|
192 |
+
$storeInDb['hide_size'][$_post_type_name][$_size_name] = '1';
|
193 |
+
}
|
194 |
}
|
195 |
}
|
196 |
}
|
readme.txt
CHANGED
@@ -62,6 +62,9 @@ Currently not.
|
|
62 |
5. Choose what image-sizes should be hidden (for what post-types), for better usability.
|
63 |
|
64 |
== Changelog ==
|
|
|
|
|
|
|
65 |
= 0.8.0 =
|
66 |
* change Constant from CPT_LANG to CROP_THUMBS_LANG
|
67 |
* change Constant from CPT_VERSION to CROP_THUMBS_VERSION
|
62 |
5. Choose what image-sizes should be hidden (for what post-types), for better usability.
|
63 |
|
64 |
== Changelog ==
|
65 |
+
= 0.8.1 =
|
66 |
+
* fix warning: when settings are saved
|
67 |
+
|
68 |
= 0.8.0 =
|
69 |
* change Constant from CPT_LANG to CROP_THUMBS_LANG
|
70 |
* change Constant from CPT_VERSION to CROP_THUMBS_VERSION
|