Autoptimize - Version 2.7.2

Version Description

  • Critical CSS: fix settings page issues with certain translation strings
  • Critical CSS: fix "inline & defer" not being "seen" on multisite network settings
  • Critical CSS: add links on path-based rules
  • Critical CSS: fix for non-asci URL's not matching rules
  • Improvement: auto-disable autoptimize on misc. page builder URL's
  • Improvement: don't change non-aggregated CSS if it already has an onload attribute
  • Image lazyload improvement: remove " from around background images
Download this release

Release Info

Developer futtta
Plugin Icon 128x128 Autoptimize
Version 2.7.2
Comparing to
See all releases

Code changes from version 2.7.1 to 2.7.2

autoptimize.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: Autoptimize
4
  * Plugin URI: https://autoptimize.com/
5
  * Description: Makes your site faster by optimizing CSS, JS, Images, Google fonts and more.
6
- * Version: 2.7.1
7
  * Author: Frank Goossens (futtta)
8
  * Author URI: https://autoptimize.com/
9
  * Text Domain: autoptimize
@@ -20,7 +20,7 @@ if ( ! defined( 'ABSPATH' ) ) {
20
  exit;
21
  }
22
 
23
- define( 'AUTOPTIMIZE_PLUGIN_VERSION', '2.7.1' );
24
 
25
  // plugin_dir_path() returns the trailing slash!
26
  define( 'AUTOPTIMIZE_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
3
  * Plugin Name: Autoptimize
4
  * Plugin URI: https://autoptimize.com/
5
  * Description: Makes your site faster by optimizing CSS, JS, Images, Google fonts and more.
6
+ * Version: 2.7.2
7
  * Author: Frank Goossens (futtta)
8
  * Author URI: https://autoptimize.com/
9
  * Text Domain: autoptimize
20
  exit;
21
  }
22
 
23
+ define( 'AUTOPTIMIZE_PLUGIN_VERSION', '2.7.2' );
24
 
25
  // plugin_dir_path() returns the trailing slash!
26
  define( 'AUTOPTIMIZE_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
classes/autoptimizeCriticalCSSBase.php CHANGED
@@ -87,8 +87,8 @@ class autoptimizeCriticalCSSBase {
87
 
88
  public static function fetch_options() {
89
  // Get options.
90
- $autoptimize_ccss_options['ao_css_defer'] = get_option( 'autoptimize_css_defer' );
91
- $autoptimize_ccss_options['ao_css_defer_inline'] = get_option( 'autoptimize_css_defer_inline' );
92
  $autoptimize_ccss_options['ao_ccss_rules_raw'] = get_option( 'autoptimize_ccss_rules', false );
93
  $autoptimize_ccss_options['ao_ccss_additional'] = get_option( 'autoptimize_ccss_additional' );
94
  $autoptimize_ccss_options['ao_ccss_queue_raw'] = get_option( 'autoptimize_ccss_queue', false );
87
 
88
  public static function fetch_options() {
89
  // Get options.
90
+ $autoptimize_ccss_options['ao_css_defer'] = autoptimizeOptionWrapper::get_option( 'autoptimize_css_defer' );
91
+ $autoptimize_ccss_options['ao_css_defer_inline'] = autoptimizeOptionWrapper::get_option( 'autoptimize_css_defer_inline' );
92
  $autoptimize_ccss_options['ao_ccss_rules_raw'] = get_option( 'autoptimize_ccss_rules', false );
93
  $autoptimize_ccss_options['ao_ccss_additional'] = get_option( 'autoptimize_ccss_additional' );
94
  $autoptimize_ccss_options['ao_ccss_queue_raw'] = get_option( 'autoptimize_ccss_queue', false );
classes/autoptimizeCriticalCSSCore.php CHANGED
@@ -70,11 +70,11 @@ class autoptimizeCriticalCSSCore {
70
  // Only if keystatus is OK and option to add CCSS for logged on users is on or user is not logged in.
71
  if ( ( $ao_ccss_keyst && 2 == $ao_ccss_keyst ) && ( $ao_ccss_loggedin || ! is_user_logged_in() ) ) {
72
  // Check for a valid CriticalCSS based on path to return its contents.
73
- $req_path = strtok( urldecode( $_SERVER['REQUEST_URI'] ), '?' );
74
  if ( ! empty( $ao_ccss_rules['paths'] ) ) {
75
  foreach ( $ao_ccss_rules['paths'] as $path => $rule ) {
76
  // explicit match OR partial match if MANUAL rule.
77
- if ( $req_path == $path || ( false == $rule['hash'] && false != $rule['file'] && strpos( $req_path, str_replace( site_url(), '', $path ) ) !== false ) ) {
78
  if ( file_exists( AO_CCSS_DIR . $rule['file'] ) ) {
79
  $_ccss_contents = file_get_contents( AO_CCSS_DIR . $rule['file'] );
80
  if ( 'none' != $_ccss_contents ) {
@@ -407,26 +407,38 @@ class autoptimizeCriticalCSSCore {
407
  }
408
 
409
  public function ao_ccss_key_validation( $key ) {
 
 
410
  // POST a dummy job to criticalcss.com to check for key validation
411
  // Prepare home URL for the request.
412
  $src_url = get_home_url();
 
 
 
 
 
 
 
 
413
  $src_url = apply_filters( 'autoptimize_filter_ccss_cron_srcurl', $src_url );
414
 
415
  // Prepare the request.
416
  $url = esc_url_raw( AO_CCSS_API . 'generate' );
417
  $args = array(
418
  'headers' => array(
419
- 'User-Agent' => 'Autoptimize CriticalCSS Power-Up v' . AO_CCSS_VER,
420
  'Content-type' => 'application/json; charset=utf-8',
421
  'Authorization' => 'JWT ' . $key,
422
  'Connection' => 'close',
423
  ),
424
  // Body must be JSON.
425
  'body' => json_encode(
426
- array(
427
- 'url' => $src_url,
428
- 'aff' => 1,
429
- 'aocssv' => AO_CCSS_VER,
 
 
430
  )
431
  ),
432
  );
70
  // Only if keystatus is OK and option to add CCSS for logged on users is on or user is not logged in.
71
  if ( ( $ao_ccss_keyst && 2 == $ao_ccss_keyst ) && ( $ao_ccss_loggedin || ! is_user_logged_in() ) ) {
72
  // Check for a valid CriticalCSS based on path to return its contents.
73
+ $req_path = strtok( $_SERVER['REQUEST_URI'], '?' );
74
  if ( ! empty( $ao_ccss_rules['paths'] ) ) {
75
  foreach ( $ao_ccss_rules['paths'] as $path => $rule ) {
76
  // explicit match OR partial match if MANUAL rule.
77
+ if ( $req_path == $path || urldecode( $req_path ) == $path || ( false == $rule['hash'] && false != $rule['file'] && strpos( $req_path, str_replace( site_url(), '', $path ) ) !== false ) ) {
78
  if ( file_exists( AO_CCSS_DIR . $rule['file'] ) ) {
79
  $_ccss_contents = file_get_contents( AO_CCSS_DIR . $rule['file'] );
80
  if ( 'none' != $_ccss_contents ) {
407
  }
408
 
409
  public function ao_ccss_key_validation( $key ) {
410
+ global $ao_ccss_noptimize;
411
+
412
  // POST a dummy job to criticalcss.com to check for key validation
413
  // Prepare home URL for the request.
414
  $src_url = get_home_url();
415
+
416
+ // Avoid AO optimizations if required by config or avoid lazyload if lazyload is active in AO.
417
+ if ( ! empty( $ao_ccss_noptimize ) ) {
418
+ $src_url .= '?ao_noptirocket=1';
419
+ } elseif ( class_exists( 'autoptimizeImages', false ) && autoptimizeImages::should_lazyload_wrapper() ) {
420
+ $src_url .= '?ao_nolazy=1';
421
+ }
422
+
423
  $src_url = apply_filters( 'autoptimize_filter_ccss_cron_srcurl', $src_url );
424
 
425
  // Prepare the request.
426
  $url = esc_url_raw( AO_CCSS_API . 'generate' );
427
  $args = array(
428
  'headers' => array(
429
+ 'User-Agent' => 'Autoptimize v' . AO_CCSS_VER,
430
  'Content-type' => 'application/json; charset=utf-8',
431
  'Authorization' => 'JWT ' . $key,
432
  'Connection' => 'close',
433
  ),
434
  // Body must be JSON.
435
  'body' => json_encode(
436
+ apply_filters( 'autoptimize_ccss_cron_api_generate_body',
437
+ array(
438
+ 'url' => $src_url,
439
+ 'aff' => 1,
440
+ 'aocssv' => AO_CCSS_VER,
441
+ )
442
  )
443
  ),
444
  );
classes/autoptimizeCriticalCSSCron.php CHANGED
@@ -485,6 +485,9 @@ class autoptimizeCriticalCSSCron {
485
  $body['forceInclude'] = $finclude;
486
  }
487
 
 
 
 
488
  // Body must be json and log it.
489
  $body = json_encode( $body );
490
  autoptimizeCriticalCSSCore::ao_ccss_log( 'criticalcss.com: POST generate request body is ' . $body, 3 );
485
  $body['forceInclude'] = $finclude;
486
  }
487
 
488
+ // Add filter to allow the body array to be altered (e.g. to add customPageHeaders).
489
+ $body = apply_filters( 'autoptimize_ccss_cron_api_generate_body', $body );
490
+
491
  // Body must be json and log it.
492
  $body = json_encode( $body );
493
  autoptimizeCriticalCSSCore::ao_ccss_log( 'criticalcss.com: POST generate request body is ' . $body, 3 );
classes/autoptimizeCriticalCSSEnqueue.php CHANGED
@@ -71,7 +71,7 @@ class autoptimizeCriticalCSSEnqueue {
71
  }
72
 
73
  // Match for types in rules if no path rule matches and if we're not enforcing paths.
74
- if ( ! $job_qualify && ( ! $ao_ccss_forcepath || ! in_array( $req_type, apply_filters( 'autoptimize_filter_ccss_coreenqueue_forcepathfortype', array( 'is_page' ) ) ) ) ) {
75
  foreach ( $ao_ccss_rules['types'] as $type => $props ) {
76
 
77
  // Prepare rule target and log.
@@ -103,7 +103,7 @@ class autoptimizeCriticalCSSEnqueue {
103
  // Should we switch to path-base AUTO-rules? Conditions:
104
  // 1. forcepath option has to be enabled (off by default)
105
  // 2. request type should be (by default, but filterable) one of is_page (removed for now: woo_is_product or woo_is_product_category).
106
- if ( $ao_ccss_forcepath && in_array( $req_type, apply_filters( 'autoptimize_filter_ccss_coreenqueue_forcepathfortype', array( 'is_page' ) ) ) ) {
107
  if ( '/' !== $req_path ) {
108
  $target_rule = 'paths|' . $req_path;
109
  } else {
@@ -195,7 +195,10 @@ class autoptimizeCriticalCSSEnqueue {
195
 
196
  // Iterates over the array to match a type.
197
  foreach ( $ao_ccss_types as $type ) {
198
- if ( strpos( $type, 'custom_post_' ) !== false ) {
 
 
 
199
  // Match custom post types.
200
  if ( get_post_type( get_the_ID() ) === substr( $type, 12 ) ) {
201
  $page_type = $type;
71
  }
72
 
73
  // Match for types in rules if no path rule matches and if we're not enforcing paths.
74
+ if ( ! $job_qualify && ( ! $ao_ccss_forcepath || ! in_array( $req_type, apply_filters( 'autoptimize_filter_ccss_coreenqueue_forcepathfortype', array( 'is_page' ) ) ) || ! apply_filters( 'autoptimize_filter_ccss_coreenqueue_ignorealltypes', false ) ) ) {
75
  foreach ( $ao_ccss_rules['types'] as $type => $props ) {
76
 
77
  // Prepare rule target and log.
103
  // Should we switch to path-base AUTO-rules? Conditions:
104
  // 1. forcepath option has to be enabled (off by default)
105
  // 2. request type should be (by default, but filterable) one of is_page (removed for now: woo_is_product or woo_is_product_category).
106
+ if ( ( $ao_ccss_forcepath && in_array( $req_type, apply_filters( 'autoptimize_filter_ccss_coreenqueue_forcepathfortype', array( 'is_page' ) ) ) ) || apply_filters( 'autoptimize_filter_ccss_coreenqueue_ignorealltypes', false ) ) {
107
  if ( '/' !== $req_path ) {
108
  $target_rule = 'paths|' . $req_path;
109
  } else {
195
 
196
  // Iterates over the array to match a type.
197
  foreach ( $ao_ccss_types as $type ) {
198
+ if ( is_404() ) {
199
+ $page_type = 'is_404';
200
+ break;
201
+ } elseif ( strpos( $type, 'custom_post_' ) !== false ) {
202
  // Match custom post types.
203
  if ( get_post_type( get_the_ID() ) === substr( $type, 12 ) ) {
204
  $page_type = $type;
classes/autoptimizeImages.php CHANGED
@@ -932,7 +932,7 @@ class autoptimizeImages
932
  // replace background-image URL with SVG placeholder.
933
  $out = str_replace( $matches[2], $placeholder, $matches[0] );
934
  // add data-bg attribute with real background-image URL for lazyload to pick up.
935
- $out = str_replace( $matches[1], $matches[1] . ' data-bg="' . trim( str_replace( "\r\n", '', $matches[2] ) ) . '"', $out );
936
  // add lazyload class to tag.
937
  $out = $this->inject_classes_in_tag( $out, "$lazyload_class " );
938
  return $out;
932
  // replace background-image URL with SVG placeholder.
933
  $out = str_replace( $matches[2], $placeholder, $matches[0] );
934
  // add data-bg attribute with real background-image URL for lazyload to pick up.
935
+ $out = str_replace( $matches[1], $matches[1] . ' data-bg="' . trim( str_replace( array( "\r\n", '"' ), '', $matches[2] ) ) . '"', $out );
936
  // add lazyload class to tag.
937
  $out = $this->inject_classes_in_tag( $out, "$lazyload_class " );
938
  return $out;
classes/autoptimizeMain.php CHANGED
@@ -334,17 +334,6 @@ class autoptimizeMain
334
  }
335
  }
336
 
337
- // also honor PageSpeed=off parameter as used by mod_pagespeed, in use by some pagebuilders,
338
- // see https://www.modpagespeed.com/doc/experiment#ModPagespeed for info on that.
339
- if ( false === $ao_noptimize && array_key_exists( 'PageSpeed', $_GET ) && 'off' === $_GET['PageSpeed'] ) {
340
- $ao_noptimize = true;
341
- }
342
-
343
- // and make sure Thrive editor doesn't get optimized HTML.
344
- if ( false === $ao_noptimize && array_key_exists( 'tve', $_GET ) && 'true' === $_GET['tve'] ) {
345
- $ao_noptimize = true;
346
- }
347
-
348
  // If setting says not to optimize logged in user and user is logged in...
349
  if ( false === $ao_noptimize && 'on' !== autoptimizeOptionWrapper::get_option( 'autoptimize_optimize_logged', 'on' ) && is_user_logged_in() && current_user_can( 'edit_posts' ) ) {
350
  $ao_noptimize = true;
@@ -361,7 +350,24 @@ class autoptimizeMain
361
  }
362
  }
363
 
364
- // Allows blocking of autoptimization on your own terms regardless of above decisions.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
365
  $ao_noptimize = (bool) apply_filters( 'autoptimize_filter_noptimize', $ao_noptimize );
366
 
367
  // Check for site being previewed in the Customizer (available since WP 4.0).
334
  }
335
  }
336
 
 
 
 
 
 
 
 
 
 
 
 
337
  // If setting says not to optimize logged in user and user is logged in...
338
  if ( false === $ao_noptimize && 'on' !== autoptimizeOptionWrapper::get_option( 'autoptimize_optimize_logged', 'on' ) && is_user_logged_in() && current_user_can( 'edit_posts' ) ) {
339
  $ao_noptimize = true;
350
  }
351
  }
352
 
353
+ // And make sure pagebuilder previews don't get optimized HTML/ JS/ CSS/ ...
354
+ if ( false === $ao_noptimize ) {
355
+ $_qs_pagebuilders = array( 'tve', 'elementor-preview', 'fl_builder', 'vc_action', 'et_fb', 'bt-beaverbuildertheme', 'ct_builder', 'fb-edit', 'siteorigin_panels_live_editor' );
356
+ foreach ( $_qs_pagebuilders as $_pagebuilder ) {
357
+ if ( array_key_exists( $_pagebuilder, $_GET ) ) {
358
+ $ao_noptimize = true;
359
+ break;
360
+ }
361
+ }
362
+ }
363
+
364
+ // Also honor PageSpeed=off parameter as used by mod_pagespeed, in use by some pagebuilders,
365
+ // see https://www.modpagespeed.com/doc/experiment#ModPagespeed for info on that.
366
+ if ( false === $ao_noptimize && array_key_exists( 'PageSpeed', $_GET ) && 'off' === $_GET['PageSpeed'] ) {
367
+ $ao_noptimize = true;
368
+ }
369
+
370
+ // And finally allows blocking of autoptimization on your own terms regardless of above decisions.
371
  $ao_noptimize = (bool) apply_filters( 'autoptimize_filter_noptimize', $ao_noptimize );
372
 
373
  // Check for site being previewed in the Customizer (available since WP 4.0).
classes/autoptimizeStyles.php CHANGED
@@ -381,7 +381,7 @@ class autoptimizeStyles extends autoptimizeBase
381
  private function optionally_defer_excluded( $tag, $url = '' )
382
  {
383
  // Defer single CSS if "inline & defer" is ON and there is inline CSS.
384
- if ( ! empty( $tag ) && $this->defer && ! empty( $this->defer_inline ) && apply_filters( 'autoptimize_filter_css_defer_excluded', true, $tag ) ) {
385
  // Get/ set (via filter) the JS to be triggers onload of the preloaded CSS.
386
  $_preload_onload = apply_filters(
387
  'autoptimize_filter_css_preload_onload',
381
  private function optionally_defer_excluded( $tag, $url = '' )
382
  {
383
  // Defer single CSS if "inline & defer" is ON and there is inline CSS.
384
+ if ( ! empty( $tag ) && false === strpos( $tag, ' onload=' ) && $this->defer && ! empty( $this->defer_inline ) && apply_filters( 'autoptimize_filter_css_defer_excluded', true, $tag ) ) {
385
  // Get/ set (via filter) the JS to be triggers onload of the preloaded CSS.
386
  $_preload_onload = apply_filters(
387
  'autoptimize_filter_css_preload_onload',
classes/critcss-inc/admin_settings_key.php CHANGED
@@ -45,7 +45,7 @@ function ao_ccss_render_key( $key, $status, $status_msg, $message, $color ) {
45
  <td>
46
  <textarea id="autoptimize_ccss_key" name="autoptimize_ccss_key" rows='3' style="width:100%;" placeholder="<?php _e( 'Please enter your criticalcss.com API key here.', 'autoptimize' ); ?>"><?php echo trim( $key ); ?></textarea>
47
  <p class="notes">
48
- <?php _e( 'Enter your <a href="https://criticalcss.com/account/api-keys?aff=1" target="_blank">criticalcss.com</a> API key above. The key is revalidated every time a new job is sent to it.<br />To obtain your API key, go to <a href="https://criticalcss.com/account/api-keys?aff=1" target="_blank">criticalcss.com</a> > Account > API Keys.<br />Requests to generate a critical CSS via the API are priced at £5 per domain per month.<br /><strong>Not sure yet? With the <a href="https://criticalcss.com/faq/?aff=1#trial" target="_blank">30 day free trial</a>, you have nothing to lose!</strong>', 'autoptimize' ); ?>
49
  </p>
50
  </td>
51
  </tr>
45
  <td>
46
  <textarea id="autoptimize_ccss_key" name="autoptimize_ccss_key" rows='3' style="width:100%;" placeholder="<?php _e( 'Please enter your criticalcss.com API key here.', 'autoptimize' ); ?>"><?php echo trim( $key ); ?></textarea>
47
  <p class="notes">
48
+ <?php _e( 'Enter your <a href="https://criticalcss.com/account/api-keys?aff=1" target="_blank">criticalcss.com</a> API key above. The key is revalidated every time a new job is sent to it.<br />To obtain your API key, go to <a href="https://criticalcss.com/account/api-keys?aff=1" target="_blank">criticalcss.com</a> > Account > API Keys.<br />Requests to generate a critical CSS via the API are priced at £5 per domain per month.<br /><strong>Not sure yet? With the <a href="https://criticalcss.com/faq/?aff=1#trial" target="_blank">30 day money back guarantee</a>, you have nothing to lose!</strong>', 'autoptimize' ); ?>
49
  </p>
50
  </td>
51
  </tr>
classes/critcss-inc/admin_settings_queue.js.php CHANGED
@@ -134,12 +134,12 @@ function delJob(queue, jid, jpath) {
134
  height: 180,
135
  modal: true,
136
  buttons: {
137
- <?php _e( 'Delete', 'autoptimize' ); ?>: function() {
138
  delete queue[jpath];
139
  updateQueue(queue);
140
  jQuery(this).dialog('close' );
141
  },
142
- <?php _e( 'Cancel', 'autoptimize' ); ?>: function() {
143
  jQuery(this).dialog('close' );
144
  }
145
  }
@@ -172,7 +172,7 @@ function retryJob(queue, jid, jpath) {
172
  height: 180,
173
  modal: true,
174
  buttons: {
175
- <?php _e( 'Retry', 'autoptimize' ); ?>: function() {
176
  <?php
177
  if ( $ao_ccss_debug ) {
178
  echo "console.log( 'SHOULD retry job:', jid[0], jpath );\n";
@@ -187,7 +187,7 @@ function retryJob(queue, jid, jpath) {
187
  updateQueue(queue);
188
  jQuery(this).dialog('close' );
189
  },
190
- <?php _e( 'Cancel', 'autoptimize' ); ?>: function() {
191
  jQuery(this).dialog('close' );
192
  }
193
  }
134
  height: 180,
135
  modal: true,
136
  buttons: {
137
+ "<?php _e( 'Delete', 'autoptimize' ); ?>": function() {
138
  delete queue[jpath];
139
  updateQueue(queue);
140
  jQuery(this).dialog('close' );
141
  },
142
+ "<?php _e( 'Cancel', 'autoptimize' ); ?>": function() {
143
  jQuery(this).dialog('close' );
144
  }
145
  }
172
  height: 180,
173
  modal: true,
174
  buttons: {
175
+ "<?php _e( 'Retry', 'autoptimize' ); ?>": function() {
176
  <?php
177
  if ( $ao_ccss_debug ) {
178
  echo "console.log( 'SHOULD retry job:', jid[0], jpath );\n";
187
  updateQueue(queue);
188
  jQuery(this).dialog('close' );
189
  },
190
+ "<?php _e( 'Cancel', 'autoptimize' ); ?>": function() {
191
  jQuery(this).dialog('close' );
192
  }
193
  }
classes/critcss-inc/admin_settings_rules.js.php CHANGED
@@ -72,7 +72,12 @@ function drawTable(critCssArray) {
72
  rmark = '';
73
  }
74
  }
75
- jQuery("#rules-list").append("<tr class='rule "+k+"Rule'><td class='type'><span class='badge " + typeClass + "'>" + type + "</span>" + rmark + "</td><td class='target'>" + i.replace(/(woo_|template_|custom_post_|edd_|bp_|bbp_)/,'') + "</td><td class='file'>" + file + "</td><td class='btn edit'><span class=\"button-secondary\" id=\"" + nodeId + "_edit\"><?php _e( 'Edit', 'autoptimize' ); ?></span></td><td class='btn delete'><span class=\"button-secondary\" id=\"" + nodeId + "_remove\"><?php _e( 'Remove', 'autoptimize' ); ?></span></td></tr>");
 
 
 
 
 
76
  jQuery("#" + nodeId + "_edit").click(function(){addEditRow(this.id);});
77
  jQuery("#" + nodeId + "_remove").click(function(){confirmRemove(this.id);});
78
  })
72
  rmark = '';
73
  }
74
  }
75
+ if ( k == "paths" ) {
76
+ target = '<a href="<?php echo AUTOPTIMIZE_WP_SITE_URL; ?>' + i + '" target="_blank">' + i + '</a>';
77
+ } else {
78
+ target = i.replace(/(woo_|template_|custom_post_|edd_|bp_|bbp_)/,'');
79
+ }
80
+ jQuery("#rules-list").append("<tr class='rule "+k+"Rule'><td class='type'><span class='badge " + typeClass + "'>" + type + "</span>" + rmark + "</td><td class='target'>" + target + "</td><td class='file'>" + file + "</td><td class='btn edit'><span class=\"button-secondary\" id=\"" + nodeId + "_edit\"><?php _e( 'Edit', 'autoptimize' ); ?></span></td><td class='btn delete'><span class=\"button-secondary\" id=\"" + nodeId + "_remove\"><?php _e( 'Remove', 'autoptimize' ); ?></span></td></tr>");
81
  jQuery("#" + nodeId + "_edit").click(function(){addEditRow(this.id);});
82
  jQuery("#" + nodeId + "_remove").click(function(){confirmRemove(this.id);});
83
  })
readme.txt CHANGED
@@ -5,7 +5,7 @@ Donate link: http://blog.futtta.be/2013/10/21/do-not-donate-to-me/
5
  Requires at least: 4.9
6
  Tested up to: 5.4
7
  Requires PHP: 5.6
8
- Stable tag: 2.7.1
9
 
10
  Autoptimize speeds up your website by optimizing JS, CSS, images (incl. lazy-load), HTML and Google Fonts, asyncing JS, removing emoji cruft and more.
11
 
@@ -295,6 +295,15 @@ Just [fork Autoptimize on Github](https://github.com/futtta/autoptimize) and cod
295
 
296
  == Changelog ==
297
 
 
 
 
 
 
 
 
 
 
298
  = 2.7.1 =
299
  * A couple of small bugfixes, see the [GitHub commit log](https://github.com/futtta/autoptimize/commits/beta).
300
 
5
  Requires at least: 4.9
6
  Tested up to: 5.4
7
  Requires PHP: 5.6
8
+ Stable tag: 2.7.2
9
 
10
  Autoptimize speeds up your website by optimizing JS, CSS, images (incl. lazy-load), HTML and Google Fonts, asyncing JS, removing emoji cruft and more.
11
 
295
 
296
  == Changelog ==
297
 
298
+ = 2.7.2 =
299
+ * Critical CSS: fix settings page issues with certain translation strings
300
+ * Critical CSS: fix "inline & defer" not being "seen" on multisite network settings
301
+ * Critical CSS: add links on path-based rules
302
+ * Critical CSS: fix for non-asci URL's not matching rules
303
+ * Improvement: auto-disable autoptimize on misc. page builder URL's
304
+ * Improvement: don't change non-aggregated CSS if it already has an onload attribute
305
+ * Image lazyload improvement: remove `&quot;` from around background images
306
+
307
  = 2.7.1 =
308
  * A couple of small bugfixes, see the [GitHub commit log](https://github.com/futtta/autoptimize/commits/beta).
309