Version Description
- fixed: no optimization when escapeshellarg() is disabled
- fixed: warning thrown by implode() when JS WebP is enabled with no WebP URLs
Download this release
Release Info
Developer | nosilver4u |
Plugin | EWWW Image Optimizer |
Version | 5.1.1 |
Comparing to | |
See all releases |
Code changes from version 5.1.0 to 5.1.1
- changelog.txt +4 -0
- classes/class-eio-alt-webp.php +9 -1
- common.php +2 -2
- ewww-image-optimizer.php +1 -1
- readme.txt +6 -31
- unique.php +1 -11
changelog.txt
CHANGED
@@ -1,3 +1,7 @@
|
|
|
|
|
|
|
|
|
|
1 |
= 5.1.0 =
|
2 |
* added: WebP-only mode for Bulk Optimizer
|
3 |
* added: JS WebP Rewriting for pull-mode CDNs via WebP URLS without Force WebP
|
1 |
+
= 5.1.1 =
|
2 |
+
* fixed: no optimization when escapeshellarg() is disabled
|
3 |
+
* fixed: warning thrown by implode() when JS WebP is enabled with no WebP URLs
|
4 |
+
|
5 |
= 5.1.0 =
|
6 |
* added: WebP-only mode for Bulk Optimizer
|
7 |
* added: JS WebP Rewriting for pull-mode CDNs via WebP URLS without Force WebP
|
classes/class-eio-alt-webp.php
CHANGED
@@ -32,13 +32,21 @@ class EIO_Alt_Webp extends EIO_Page_Parser {
|
|
32 |
protected $parsing_exactdn = false;
|
33 |
|
34 |
/**
|
35 |
-
* Allowed paths for
|
36 |
*
|
37 |
* @access protected
|
38 |
* @var array $webp_paths
|
39 |
*/
|
40 |
protected $webp_paths = array();
|
41 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
42 |
/**
|
43 |
* Register (once) actions and filters for Alt WebP.
|
44 |
*/
|
32 |
protected $parsing_exactdn = false;
|
33 |
|
34 |
/**
|
35 |
+
* Allowed paths for JS WebP.
|
36 |
*
|
37 |
* @access protected
|
38 |
* @var array $webp_paths
|
39 |
*/
|
40 |
protected $webp_paths = array();
|
41 |
|
42 |
+
/**
|
43 |
+
* Allowed domains for JS WebP.
|
44 |
+
*
|
45 |
+
* @access protected
|
46 |
+
* @var array $webp_domains
|
47 |
+
*/
|
48 |
+
protected $webp_domains = array();
|
49 |
+
|
50 |
/**
|
51 |
* Register (once) actions and filters for Alt WebP.
|
52 |
*/
|
common.php
CHANGED
@@ -21,7 +21,7 @@ if ( ! defined( 'ABSPATH' ) ) {
|
|
21 |
exit;
|
22 |
}
|
23 |
|
24 |
-
define( 'EWWW_IMAGE_OPTIMIZER_VERSION', '
|
25 |
|
26 |
// Initialize a couple globals.
|
27 |
$eio_debug = '';
|
@@ -8973,7 +8973,7 @@ function ewww_image_optimizer_options( $network = 'singlesite' ) {
|
|
8973 |
ewwwio_help_link( 'https://docs.ewww.io/article/16-ewww-io-and-webp-images', '5854745ac697912ffd6c1c89' ) .
|
8974 |
"</th><td><span><input type='checkbox' id='ewww_image_optimizer_webp' name='ewww_image_optimizer_webp' value='true' " .
|
8975 |
( ewww_image_optimizer_get_option( 'ewww_image_optimizer_webp' ) ? "checked='true'" : '' ) . ' /> ' .
|
8976 |
-
esc_html__( 'JPG to WebP conversion is lossy, but quality loss is minimal. PNG to WebP conversion is lossless
|
8977 |
"</span>\n<p class='description'>" . esc_html__( 'Originals are never deleted, and WebP images should only be served to supported browsers.', 'ewww-image-optimizer' ) .
|
8978 |
" <a href='#ewww-webp-rewrite'>" . ( ewww_image_optimizer_get_option( 'ewww_image_optimizer_webp' ) && ! ewww_image_optimizer_get_option( 'ewww_image_optimizer_webp_for_cdn' ) ? esc_html__( 'You can use the rewrite rules below to serve WebP images with Apache.', 'ewww-image-optimizer' ) : '' ) . "</a></td></tr>\n";
|
8979 |
ewwwio_debug_message( 'webp conversion: ' . ( ewww_image_optimizer_get_option( 'ewww_image_optimizer_webp' ) ? 'on' : 'off' ) );
|
21 |
exit;
|
22 |
}
|
23 |
|
24 |
+
define( 'EWWW_IMAGE_OPTIMIZER_VERSION', '511.0' );
|
25 |
|
26 |
// Initialize a couple globals.
|
27 |
$eio_debug = '';
|
8973 |
ewwwio_help_link( 'https://docs.ewww.io/article/16-ewww-io-and-webp-images', '5854745ac697912ffd6c1c89' ) .
|
8974 |
"</th><td><span><input type='checkbox' id='ewww_image_optimizer_webp' name='ewww_image_optimizer_webp' value='true' " .
|
8975 |
( ewww_image_optimizer_get_option( 'ewww_image_optimizer_webp' ) ? "checked='true'" : '' ) . ' /> ' .
|
8976 |
+
esc_html__( 'JPG to WebP conversion is lossy, but quality loss is minimal. PNG to WebP conversion is lossless.', 'ewww-image-optimizer' ) .
|
8977 |
"</span>\n<p class='description'>" . esc_html__( 'Originals are never deleted, and WebP images should only be served to supported browsers.', 'ewww-image-optimizer' ) .
|
8978 |
" <a href='#ewww-webp-rewrite'>" . ( ewww_image_optimizer_get_option( 'ewww_image_optimizer_webp' ) && ! ewww_image_optimizer_get_option( 'ewww_image_optimizer_webp_for_cdn' ) ? esc_html__( 'You can use the rewrite rules below to serve WebP images with Apache.', 'ewww-image-optimizer' ) : '' ) . "</a></td></tr>\n";
|
8979 |
ewwwio_debug_message( 'webp conversion: ' . ( ewww_image_optimizer_get_option( 'ewww_image_optimizer_webp' ) ? 'on' : 'off' ) );
|
ewww-image-optimizer.php
CHANGED
@@ -13,7 +13,7 @@ Plugin Name: EWWW Image Optimizer
|
|
13 |
Plugin URI: https://wordpress.org/plugins/ewww-image-optimizer/
|
14 |
Description: Reduce file sizes for images within WordPress including NextGEN Gallery and GRAND FlAGallery. Uses jpegtran, optipng/pngout, and gifsicle.
|
15 |
Author: Exactly WWW
|
16 |
-
Version: 5.1.
|
17 |
Author URI: https://ewww.io/
|
18 |
License: GPLv3
|
19 |
*/
|
13 |
Plugin URI: https://wordpress.org/plugins/ewww-image-optimizer/
|
14 |
Description: Reduce file sizes for images within WordPress including NextGEN Gallery and GRAND FlAGallery. Uses jpegtran, optipng/pngout, and gifsicle.
|
15 |
Author: Exactly WWW
|
16 |
+
Version: 5.1.1
|
17 |
Author URI: https://ewww.io/
|
18 |
License: GPLv3
|
19 |
*/
|
readme.txt
CHANGED
@@ -5,10 +5,10 @@ Tags: optimize, image, convert, webp, resize, compress, lazy load, optimization,
|
|
5 |
Requires at least: 5.0
|
6 |
Tested up to: 5.3
|
7 |
Requires PHP: 5.6
|
8 |
-
Stable tag: 5.1.
|
9 |
License: GPLv3
|
10 |
|
11 |
-
Speed up your website
|
12 |
|
13 |
== Description ==
|
14 |
|
@@ -173,6 +173,10 @@ https://developers.google.com/web/tools/lighthouse/audits/optimize-images
|
|
173 |
* Feature requests can be viewed and submitted at https://github.com/nosilver4u/ewww-image-optimizer/labels/enhancement
|
174 |
* If you would like to help translate this plugin in your language, get started here: https://translate.wordpress.org/projects/wp-plugins/ewww-image-optimizer/
|
175 |
|
|
|
|
|
|
|
|
|
176 |
= 5.1.0 =
|
177 |
* added: WebP-only mode for Bulk Optimizer
|
178 |
* added: JS WebP Rewriting for pull-mode CDNs via WebP URLS without Force WebP
|
@@ -199,35 +203,6 @@ https://developers.google.com/web/tools/lighthouse/audits/optimize-images
|
|
199 |
* fixed: data-width and data-height attributes missing when JS WebP active
|
200 |
* security: rewrote escapeshellarg() wrapper to be more secure
|
201 |
|
202 |
-
= 4.9.3 =
|
203 |
-
* fixed: ExactDN incorrectly scales Elementor background images rather than cropping
|
204 |
-
* fixed: ExactDN cannot work with Divi/Elementor background images due to use of external CSS files
|
205 |
-
* fixed: JS WebP rewriting picture tags that already have WebP markup in Force WebP mode
|
206 |
-
* fixed: JS WebP incorrectly parses GIF/SVG images in Force WebP mode
|
207 |
-
* fixed: JS WebP does not support lazy load + infinite scroll
|
208 |
-
* fixed: Lazy Load auto-scaling breaks if background image is enclosed in encoded quotes
|
209 |
-
* fixed: GRAND FlaGallery integration broken by hook suffix change
|
210 |
-
|
211 |
-
= 4.9.2 =
|
212 |
-
* fixed: generating lazy load PNG placeholders with large heights causes 500 errors
|
213 |
-
* fixed: error when importing media via WordPress Importer plugin
|
214 |
-
* fixed: error with WP/LR Sync
|
215 |
-
|
216 |
-
= 4.9.1 =
|
217 |
-
* fixed: error on settings screen when JS WebP is enabled
|
218 |
-
|
219 |
-
= 4.9.0 =
|
220 |
-
* added: Lazy Load background image support for section elements
|
221 |
-
* added: ExactDN background image support for li,span, and section elements
|
222 |
-
* added: lazysizes print plugin, enable via EWWW_IMAGE_OPTIMIZER_LAZY_PRINT constant
|
223 |
-
* added: compatibility with upcoming Easy Image Optimizer
|
224 |
-
* changed: automatic compression disabled during WP/LR Sync with admin notice
|
225 |
-
* changed: Lazy Load PNG placeholders capped at 1920px wide to prevent errors
|
226 |
-
* changed: use ExactDN, when active, for Lazy Load PNG placeholders
|
227 |
-
* changed: EWWW_MEMORY_LIMIT renamed to EIO_MEMORY_LIMIT for setting plugin memory limit
|
228 |
-
* fixed: WebP test image not refreshing after inserting .htaccess rules
|
229 |
-
* fixed: errors when manually adding lazysizes script
|
230 |
-
|
231 |
= Earlier versions =
|
232 |
Please refer to the separate changelog.txt file.
|
233 |
|
5 |
Requires at least: 5.0
|
6 |
Tested up to: 5.3
|
7 |
Requires PHP: 5.6
|
8 |
+
Stable tag: 5.1.1
|
9 |
License: GPLv3
|
10 |
|
11 |
+
Speed up your website to better connect with your visitors. Properly compress and size/scale images. Includes lazy load and WebP convert.
|
12 |
|
13 |
== Description ==
|
14 |
|
173 |
* Feature requests can be viewed and submitted at https://github.com/nosilver4u/ewww-image-optimizer/labels/enhancement
|
174 |
* If you would like to help translate this plugin in your language, get started here: https://translate.wordpress.org/projects/wp-plugins/ewww-image-optimizer/
|
175 |
|
176 |
+
= 5.1.1 =
|
177 |
+
* fixed: no optimization when escapeshellarg() is disabled
|
178 |
+
* fixed: warning thrown by implode() when JS WebP is enabled with no WebP URLs
|
179 |
+
|
180 |
= 5.1.0 =
|
181 |
* added: WebP-only mode for Bulk Optimizer
|
182 |
* added: JS WebP Rewriting for pull-mode CDNs via WebP URLS without Force WebP
|
203 |
* fixed: data-width and data-height attributes missing when JS WebP active
|
204 |
* security: rewrote escapeshellarg() wrapper to be more secure
|
205 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
206 |
= Earlier versions =
|
207 |
Please refer to the separate changelog.txt file.
|
208 |
|
unique.php
CHANGED
@@ -1224,18 +1224,8 @@ function ewww_image_optimizer_escapeshellarg( $arg ) {
|
|
1224 |
$safe_arg = str_replace( '!', ' ', $safe_arg );
|
1225 |
$safe_arg = str_replace( '"', ' ', $safe_arg );
|
1226 |
return '"' . $safe_arg . '"';
|
1227 |
-
} elseif ( ewww_image_optimizer_function_exists( 'setlocale' ) ) {
|
1228 |
-
$current_locale = strtolower( setlocale( LC_CTYPE, 0 ) );
|
1229 |
-
if ( false === strpos( $current_locale, 'utf8' ) && false === strpos( $current_locale, 'utf-8' ) ) {
|
1230 |
-
$changed_local = true;
|
1231 |
-
ewwwio_debug_message( "setting locale, found $current_locale" );
|
1232 |
-
setlocale( LC_CTYPE, 'en_US.UTF-8' );
|
1233 |
-
}
|
1234 |
-
}
|
1235 |
-
$safe_arg = escapeshellarg( $arg );
|
1236 |
-
if ( ! empty( $changed_local ) ) {
|
1237 |
-
setlocale( LC_CTYPE, $current_locale );
|
1238 |
}
|
|
|
1239 |
return $safe_arg;
|
1240 |
}
|
1241 |
|
1224 |
$safe_arg = str_replace( '!', ' ', $safe_arg );
|
1225 |
$safe_arg = str_replace( '"', ' ', $safe_arg );
|
1226 |
return '"' . $safe_arg . '"';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1227 |
}
|
1228 |
+
$safe_arg = "'" . str_replace( "'", "'\\''", $arg ) . "'";
|
1229 |
return $safe_arg;
|
1230 |
}
|
1231 |
|