WebP Express - Version 0.6.2

Version Description

= 0.6.0 = Adding caching option, fixed imagick converter, added gmagick converter and more!

Download this release

Release Info

Developer rosell.dk
Plugin Icon 128x128 WebP Express
Version 0.6.2
Comparing to
See all releases

Code changes from version 0.6.1 to 0.6.2

README.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.bitwise-it.dk/contact
4
  Tags: webp, images, performance
5
  Requires at least: 4.0
6
  Tested up to: 4.9
7
- Stable tag: 0.6.1
8
  Requires PHP: 5.6
9
  License: GPLv3
10
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
4
  Tags: webp, images, performance
5
  Requires at least: 4.0
6
  Tested up to: 4.9
7
+ Stable tag: 0.6.2
8
  Requires PHP: 5.6
9
  License: GPLv3
10
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
lib/options/css/webp-express-options-page.css CHANGED
@@ -151,11 +151,15 @@
151
  #converters li.operational .popup {
152
  background-color: #80ff80;
153
  }
154
- /* #converters li .status:hover .popup */
155
  #converters li:hover .status .popup,
156
  .help:hover .popup {
157
  display: block;
158
  }
 
 
 
 
159
 
160
  .help .popup {
161
  min-width: 250px;
151
  #converters li.operational .popup {
152
  background-color: #80ff80;
153
  }
154
+ /* #converters li .status:hover .popup,*/
155
  #converters li:hover .status .popup,
156
  .help:hover .popup {
157
  display: block;
158
  }
159
+ #converters.dragging li:hover .status .popup {
160
+ display: none;
161
+
162
+ }
163
 
164
  .help .popup {
165
  min-width: 250px;
lib/options/enqueue_scripts.php CHANGED
@@ -10,7 +10,7 @@ wp_register_script(
10
  'webp-express-options-page',
11
  plugins_url('js/webp-express-options-page.js', __FILE__),
12
  ['sortable'],
13
- '0.6.0-1'
14
  );
15
  wp_enqueue_script('webp-express-options-page');
16
 
@@ -25,7 +25,7 @@ wp_register_style(
25
  'webp-express-options-page-css',
26
  plugins_url('css/webp-express-options-page.css', __FILE__),
27
  null,
28
- '0.6.0'
29
  );
30
  wp_enqueue_style('webp-express-options-page-css');
31
 
10
  'webp-express-options-page',
11
  plugins_url('js/webp-express-options-page.js', __FILE__),
12
  ['sortable'],
13
+ '0.6.0-2'
14
  );
15
  wp_enqueue_script('webp-express-options-page');
16
 
25
  'webp-express-options-page-css',
26
  plugins_url('css/webp-express-options-page.css', __FILE__),
27
  null,
28
+ '0.6.0-2'
29
  );
30
  wp_enqueue_style('webp-express-options-page-css');
31
 
lib/options/js/webp-express-options-page.js CHANGED
@@ -171,6 +171,12 @@ function setConvertersHTML() {
171
  el.innerHTML = html;
172
 
173
  var sortable = Sortable.create(el, {
 
 
 
 
 
 
174
  store: {
175
  get: function() {
176
  var order = [];
@@ -373,7 +379,7 @@ function testConverter(id) {
373
  url += '&max-quality=' + document.getElementById('max_quality').value;
374
  }
375
  if (document.getElementById('quality_specific')) {
376
- url += '&quality=' + document.getElementById('quality_specific').value;
377
  }
378
  //url += '&method=' + document.getElementsByName('webp_express_method')[0].value;
379
 
171
  el.innerHTML = html;
172
 
173
  var sortable = Sortable.create(el, {
174
+ onChoose: function() {
175
+ document.getElementById('converters').className = 'dragging';
176
+ },
177
+ onUnchoose: function() {
178
+ document.getElementById('converters').className = '';
179
+ },
180
  store: {
181
  get: function() {
182
  var order = [];
379
  url += '&max-quality=' + document.getElementById('max_quality').value;
380
  }
381
  if (document.getElementById('quality_specific')) {
382
+ url += '&quality=' + document.getElementById('quality_specific').value;
383
  }
384
  //url += '&method=' + document.getElementsByName('webp_express_method')[0].value;
385
 
webp-express.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: WebP Express
4
  * Plugin URI: https://github.com/rosell-dk/webp-express
5
  * Description: Serve autogenerated WebP images instead of jpeg/png to browsers that supports WebP. Works on anything (media library images, galleries, theme images etc).
6
- * Version: 0.6.1
7
  * Author: Bjørn Rosell
8
  * Author URI: https://www.bitwise-it.dk
9
  * License: GPL2
3
  * Plugin Name: WebP Express
4
  * Plugin URI: https://github.com/rosell-dk/webp-express
5
  * Description: Serve autogenerated WebP images instead of jpeg/png to browsers that supports WebP. Works on anything (media library images, galleries, theme images etc).
6
+ * Version: 0.6.2
7
  * Author: Bjørn Rosell
8
  * Author URI: https://www.bitwise-it.dk
9
  * License: GPL2
wod/webp-on-demand.php CHANGED
@@ -15,9 +15,11 @@ $json = fread($handle, filesize($configFilename));
15
  fclose($handle);
16
 
17
  $options = json_decode($json, true);
18
- //print_r($options);
 
19
 
20
  $options['require-for-conversion'] = 'webp-on-demand-2.inc';
 
21
 
22
  $gmagickHere = false;
23
  foreach ($options['converters'] as &$converter) {
@@ -34,7 +36,7 @@ foreach ($options['converters'] as &$converter) {
34
  }
35
  }
36
  if (!$gmagickHere) {
37
- $options['converters'][] = 'gmagick';
38
  }
39
 
40
  if ($options['forward-query-string']) {
@@ -63,6 +65,10 @@ if (substr($source, 0, strlen($applicationRoot)) === $applicationRoot) {
63
  }
64
  //$destination = $imageRoot . $source . '.webp';
65
 
 
 
 
 
66
 
67
  //echo $source . '<br>';
68
  //echo $destination . '<br>';
15
  fclose($handle);
16
 
17
  $options = json_decode($json, true);
18
+ //echo '<pre>' . print_r($options, true) . '</pre>';
19
+ //exit;
20
 
21
  $options['require-for-conversion'] = 'webp-on-demand-2.inc';
22
+ //$options['require-for-conversion'] = '../../../autoload.php';
23
 
24
  $gmagickHere = false;
25
  foreach ($options['converters'] as &$converter) {
36
  }
37
  }
38
  if (!$gmagickHere) {
39
+ // $options['converters'][] = 'gmagick';
40
  }
41
 
42
  if ($options['forward-query-string']) {
65
  }
66
  //$destination = $imageRoot . $source . '.webp';
67
 
68
+ if ($options['show-report']) {
69
+ // echo '<pre>' . print_r($options, true) . '</pre>';
70
+
71
+ }
72
 
73
  //echo $source . '<br>';
74
  //echo $destination . '<br>';