Version Description
- Added: Check required PHP version
Download this release
Release Info
Developer | webdorado |
Plugin | Image Optimizer by 10web – Image Optimizer and Compression plugin |
Version | 1.0.1 |
Comparing to | |
See all releases |
Code changes from version 1.0.0 to 1.0.1
- .gitignore +3 -0
- io-wd.php +9 -5
- iowd_class.php +5 -2
- readme.txt +5 -2
.gitignore
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
1 |
+
# Created by .ignore support plugin (hsz.mobi)
|
2 |
+
/vendor/
|
3 |
+
.idea/*
|
io-wd.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
* Plugin Name: Image Optimizer WD
|
5 |
* Plugin URI: https://web-dorado.com/products/wordpress-image-optimizer.html
|
6 |
* Description: Image Optimizer WordPress plugin enables you to resize, compress and optimize PNG, JPG, GIF files while maintaining image quality.
|
7 |
-
* Version: 1.0.
|
8 |
* Author: WebDorado
|
9 |
* Author URI: https://web-dorado.com/
|
10 |
* License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
|
@@ -28,7 +28,9 @@ define('IOWD_API_URL', "https://optimizer.web-dorado.com/api/");
|
|
28 |
|
29 |
setlocale(LC_ALL, 'en_US.UTF-8');
|
30 |
|
31 |
-
|
|
|
|
|
32 |
|
33 |
if (class_exists("WP_REST_Controller")) {
|
34 |
require_once('iowd-rest.php');
|
@@ -40,11 +42,13 @@ if (class_exists("WP_REST_Controller")) {
|
|
40 |
|
41 |
if (is_admin() || (defined('DOING_CRON') && DOING_CRON)) {
|
42 |
require_once('iowd_class.php');
|
43 |
-
require_once(IOWD_DIR_INCLUDES . '/iowd-media-library.php');
|
44 |
register_activation_hook(__FILE__, array('IOWD', 'activate'));
|
45 |
-
add_action('plugins_loaded', array('IOWD', 'get_instance'));
|
46 |
|
47 |
-
|
|
|
|
|
|
|
|
|
48 |
|
49 |
}
|
50 |
|
4 |
* Plugin Name: Image Optimizer WD
|
5 |
* Plugin URI: https://web-dorado.com/products/wordpress-image-optimizer.html
|
6 |
* Description: Image Optimizer WordPress plugin enables you to resize, compress and optimize PNG, JPG, GIF files while maintaining image quality.
|
7 |
+
* Version: 1.0.1
|
8 |
* Author: WebDorado
|
9 |
* Author URI: https://web-dorado.com/
|
10 |
* License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
|
28 |
|
29 |
setlocale(LC_ALL, 'en_US.UTF-8');
|
30 |
|
31 |
+
if (version_compare(phpversion(), "5.4", '>')){
|
32 |
+
require_once('vendor/autoload.php');
|
33 |
+
}
|
34 |
|
35 |
if (class_exists("WP_REST_Controller")) {
|
36 |
require_once('iowd-rest.php');
|
42 |
|
43 |
if (is_admin() || (defined('DOING_CRON') && DOING_CRON)) {
|
44 |
require_once('iowd_class.php');
|
|
|
45 |
register_activation_hook(__FILE__, array('IOWD', 'activate'));
|
|
|
46 |
|
47 |
+
if (version_compare(phpversion(), "5.4", '>')){
|
48 |
+
require_once(IOWD_DIR_INCLUDES . '/iowd-media-library.php');
|
49 |
+
add_action('plugins_loaded', array('IOWD', 'get_instance'));
|
50 |
+
register_deactivation_hook(__FILE__, array('IOWD', 'deactivate'));
|
51 |
+
}
|
52 |
|
53 |
}
|
54 |
|
iowd_class.php
CHANGED
@@ -8,7 +8,7 @@ class IOWD
|
|
8 |
{
|
9 |
|
10 |
protected static $instance = null;
|
11 |
-
private static $version = '1.0.
|
12 |
private static $page;
|
13 |
private $reg_autoloader = false;
|
14 |
private $options = array();
|
@@ -67,7 +67,10 @@ class IOWD
|
|
67 |
|
68 |
public static function activate()
|
69 |
{
|
70 |
-
|
|
|
|
|
|
|
71 |
//delete_transient('iowd_update_check');
|
72 |
require_once IOWD_DIR_INCLUDES . "/iowd-helper.php";
|
73 |
IOWD_Helper::update_already_used();
|
8 |
{
|
9 |
|
10 |
protected static $instance = null;
|
11 |
+
private static $version = '1.0.1';
|
12 |
private static $page;
|
13 |
private $reg_autoloader = false;
|
14 |
private $options = array();
|
67 |
|
68 |
public static function activate()
|
69 |
{
|
70 |
+
if (version_compare(phpversion(), "5.4", '<')){
|
71 |
+
echo "<div class='error'><p>" . __("Image Optimizer plugin requires PHP 5.4 or higher.", IOWD_PREFIX) . "</p></div>";
|
72 |
+
wp_die();
|
73 |
+
}
|
74 |
//delete_transient('iowd_update_check');
|
75 |
require_once IOWD_DIR_INCLUDES . "/iowd-helper.php";
|
76 |
IOWD_Helper::update_already_used();
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: https://web-dorado.com/products/wordpress-image-optimizer.html
|
|
4 |
Tags: : compress, image, images optimization, performance, photos, lossless, optimize
|
5 |
Requires at least: 3.9
|
6 |
Tested up to: 4.8
|
7 |
-
Stable tag: 1.0.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -36,7 +36,7 @@ The plugin provides statistics, so you can always know how many images were opti
|
|
36 |
* Shrink JPEG, PNG, GIF files
|
37 |
* Optimize 1000 images every month
|
38 |
* Convert from one image type to another
|
39 |
-
*
|
40 |
* Lossless and Lossy Conversions without losing image quality or minimal quality loss
|
41 |
* Pick exactly which sizes you want to compress (i.e. thumbnail, medium, etc.)
|
42 |
* Automatic optimization options
|
@@ -54,6 +54,9 @@ Upgrade to [Image Optimizer WD Pro](https://web-dorado.com/products/wordpress-im
|
|
54 |
|
55 |
== Changelog ==
|
56 |
|
|
|
|
|
|
|
57 |
= 1.0.0 =
|
58 |
* Initial version
|
59 |
|
4 |
Tags: : compress, image, images optimization, performance, photos, lossless, optimize
|
5 |
Requires at least: 3.9
|
6 |
Tested up to: 4.8
|
7 |
+
Stable tag: 1.0.1
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
36 |
* Shrink JPEG, PNG, GIF files
|
37 |
* Optimize 1000 images every month
|
38 |
* Convert from one image type to another
|
39 |
+
* 2 Modes - conservative, balanced
|
40 |
* Lossless and Lossy Conversions without losing image quality or minimal quality loss
|
41 |
* Pick exactly which sizes you want to compress (i.e. thumbnail, medium, etc.)
|
42 |
* Automatic optimization options
|
54 |
|
55 |
== Changelog ==
|
56 |
|
57 |
+
= 1.0.1 =
|
58 |
+
* Added: Check required PHP version
|
59 |
+
|
60 |
= 1.0.0 =
|
61 |
* Initial version
|
62 |
|