PluginProbe
WP-Optimize – Cache, Compress images, Minify & Clean database to boost page speed & performance / 4.7.0
WP-Optimize – Cache, Compress images, Minify & Clean database to boost page speed & performance v4.7.0
4.7.0 4.6.1 4.6.0 4.5.5 4.5.4 4.5.3 4.5.2 3.2.20 3.2.21 3.2.22 3.2.3 3.2.5 3.2.6 3.2.7 3.2.9 3.3.0 3.3.1 3.3.2 3.4.0 3.4.1 3.4.2 3.5.0 3.6.0 3.7.0 3.7.1 All 111 releases
← All changes | templates/minify/advanced-tab.php +51 -45 3.2.20 → 4.7.0 View file →
@@ -1,5 +1,5 @@
1 -<?php if (!defined('WPO_VERSION')) die('No direct access allowed'); ?>
1 +<?php if (!defined('ABSPATH')) die('No direct access allowed'); ?>
2 2 <div id="wp-optimize-minify-advanced" class="wpo_section wpo_group">
3 3 <h3><?php esc_html_e('Minify cache information', 'wp-optimize'); ?></h3>
4 4 <div class="wpo-fieldgroup">
5 5 <p>
@@ -6,9 +6,9 @@
6 6 <?php esc_html_e('Current cache path:', 'wp-optimize'); ?>
7 7 <strong class="wpo_min_cache_path">
8 8 <?php
9 9
10 - $cache_path = WPO_MINIFY_PHP_VERSION_MET ? WP_Optimize_Minify_Cache_Functions::cache_path() : array("cachedir" => __('none', 'wp-optimize'));
10 + $cache_path = WP_Optimize_Minify_Cache_Functions::cache_path();
11 11 echo esc_html($cache_path['cachedir']);
12 12 ?>
13 13 </strong>
14 14 </p>
@@ -137,14 +137,14 @@
137 137 <?php esc_html_e('Enable this option to see or edit those files.', 'wp-optimize'); ?></p>
138 138 <div class="wpo-minify-default-exclusions<?php echo $wpo_minify_options['edit_default_exclutions'] ? '' : ' hidden'; ?>">
139 139 <h3><?php esc_html_e('Known incompatible files', 'wp-optimize'); ?></h3>
140 140 <fieldset>
141 - <label for="ignore_list">
141 + <p>
142 142 <?php esc_html_e('List of files that can\'t or shouldn\'t be minified or merged.', 'wp-optimize'); ?>
143 143 <?php esc_html_e('Do not edit this if you are not sure what it is.', 'wp-optimize'); ?>
144 144 <br><?php esc_html_e('Tick the checkbox to merge / minify the corresponding file anyways.', 'wp-optimize'); ?>
145 - <span tabindex="0" data-tooltip="<?php esc_attr_e('Files that have been consistently reported by other users to cause trouble when merged', 'wp-optimize');?>"><span class="dashicons dashicons-editor-help"></span> </span>
146 - </label>
145 + <span tabindex="0" class="wpo-tooltip" data-tooltip="<?php esc_attr_e('Files that have been consistently reported by other users to cause trouble when merged', 'wp-optimize');?>"><span class="dashicons dashicons-editor-help"></span> </span>
146 + </p>
147 147 <?php
148 148 $user_excluded_ignorelist_items = is_array($wpo_minify_options['ignore_list']) ? $wpo_minify_options['ignore_list'] : array();
149 149 if (empty($default_ignore)) {
150 150 echo '<p>'.esc_html__('Refresh the page to see the list', 'wp-optimize').'</p>';
@@ -159,13 +159,13 @@
159 159 </fieldset>
160 160
161 161 <h3><?php esc_html_e('IE incompatible files', 'wp-optimize'); ?></h3>
162 162 <fieldset>
163 - <label for="blacklist">
163 + <p>
164 164 <?php esc_html_e('List of excluded files used for IE compatibility.', 'wp-optimize'); ?>
165 165 <?php esc_html_e('Do not edit this if you are not sure what it is.', 'wp-optimize'); ?>
166 166 <br><?php esc_html_e('Tick the checkbox to merge / minify the corresponding file anyways.', 'wp-optimize'); ?>
167 - </label>
167 + </p>
168 168 <?php
169 169 $user_excluded_blacklist_items = is_array($wpo_minify_options['blacklist']) ? $wpo_minify_options['blacklist'] : array();
170 170 if (empty($default_ie_blacklist)) {
171 171 echo '<p>'.esc_html__('Refresh the page to see the list', 'wp-optimize').'</p>';
@@ -183,8 +183,9 @@
183 183
184 184 <?php if (WP_OPTIMIZE_SHOW_MINIFY_ADVANCED) : ?>
185 185 <div class="wpo-fieldgroup">
186 186 <fieldset>
187 + <div class="wpo-fieldgroup__subgroup">
187 188 <br>
188 189 <label for="enabled_css_preload">
189 190 <input
190 191 name="enabled_css_preload"
@@ -193,11 +194,12 @@
193 194 value="1"
194 195 <?php echo checked($wpo_minify_options['enabled_css_preload']); ?>
195 196 >
196 197 <?php esc_html_e('Enable WP-O Minify CSS files preloading', 'wp-optimize'); ?>
197 - <span tabindex="0" data-tooltip="<?php esc_attr_e('Automatically create HTTP headers for WP-O Minify-generated CSS files (when not inlined)', 'wp-optimize');?>"><span class="dashicons dashicons-editor-help"></span> </span>
198 198 </label>
199 - <br>
199 + <span tabindex="0" class="wpo-tooltip" data-tooltip="<?php esc_attr_e('Automatically create HTTP headers for WP-O Minify-generated CSS files (when not inlined)', 'wp-optimize');?>"><span class="dashicons dashicons-editor-help"></span> </span>
200 + </div>
201 + <div class="wpo-fieldgroup__subgroup">
200 202 <label for="enabled_js_preload">
201 203 <input
202 204 name="enabled_js_preload"
203 205 type="checkbox"
@@ -205,12 +207,13 @@
205 207 value="1"
206 208 <?php echo checked($wpo_minify_options['enabled_js_preload']); ?>
207 209 >
208 210 <?php esc_html_e('Enable WP-O Minify JavaScript files Preload', 'wp-optimize'); ?>
209 - <span tabindex="0" data-tooltip="<?php esc_attr_e('Automatically create HTTP headers for WP-O Minify-generated JS files', 'wp-optimize');?>"><span class="dashicons dashicons-editor-help"></span> </span>
210 211 </label>
211 - </fieldset>
212 - </div>
212 + <span tabindex="0" class="wpo-tooltip" data-tooltip="<?php esc_attr_e('Automatically create HTTP headers for WP-O Minify-generated JS files', 'wp-optimize');?>"><span class="dashicons dashicons-editor-help"></span> </span>
213 + </div>
214 + </fieldset>
215 + </div>
213 216 <h3 class="title">
214 217 <?php esc_html_e('HTTP Headers', 'wp-optimize'); ?>
215 218 </h3>
216 219 <p class="wpo_min-bold-green">
@@ -259,27 +262,32 @@
259 262
260 263 <h3><?php esc_html_e('External URLs to merge', 'wp-optimize'); ?></h3>
261 264 <div class="wpo-fieldgroup">
262 265 <fieldset>
263 - <label for="merge_allowed_urls">
264 - <?php esc_html_e('List of external domains that can be fetched and merged:', 'wp-optimize'); ?>
265 - <span tabindex="0" data-tooltip="<?php esc_attr_e('Add any external "domain" for JavaScript or CSS files that can be fetched and merged by WP-Optimize, e.g.: cdnjs.cloudflare.com', 'wp-optimize');?>"><span class="dashicons dashicons-editor-help"></span> </span>
266 - </label>
267 - <textarea
268 - name="merge_allowed_urls"
269 - rows="7"
270 - cols="50"
271 - id="merge_allowed_urls"
272 - class="large-text code"
273 - placeholder="<?php esc_attr_e('e.g.: example.com', 'wp-optimize'); ?>"
274 - ><?php echo esc_textarea($wpo_minify_options['merge_allowed_urls']); ?></textarea>
266 + <div class="wpo-fieldgroup__subgroup">
267 + <label for="merge_allowed_urls">
268 + <?php esc_html_e('List of external domains that can be fetched and merged:', 'wp-optimize'); ?>
269 + </label>
270 + <span tabindex="0" class="wpo-tooltip" data-tooltip="<?php esc_attr_e('Add any external "domain" for JavaScript or CSS files that can be fetched and merged by WP-Optimize, e.g.: cdnjs.cloudflare.com', 'wp-optimize');?>"><span class="dashicons dashicons-editor-help"></span> </span>
271 + <textarea
272 + name="merge_allowed_urls"
273 + rows="7"
274 + cols="50"
275 + id="merge_allowed_urls"
276 + class="large-text code"
277 + placeholder="<?php esc_attr_e('e.g.: example.com', 'wp-optimize'); ?>"
278 + ><?php echo esc_textarea($wpo_minify_options['merge_allowed_urls']); ?></textarea>
279 + </div>
275 280 </fieldset>
276 281 </div>
277 282
278 283 <h1><?php esc_html_e('CDN Options', 'wp-optimize'); ?></h1>
279 284 <p class="wpo_min-bold-green">
280 - <?php printf(esc_html__('When the "Enable defer on processed JavaScript files" option is enabled, JavaScript and CSS files will not be loaded from the CDN due to %scompatibility%s reasons.', 'wp-optimize'), '<a target="_blank" href="https://www.chromestatus.com/feature/5718547946799104">', '</a>'); ?>
281 - <?php esc_html_e('However, you can define a CDN Domain below, in order to use it for all of the static assets "inside" your CSS and JS files.', 'wp-optimize'); ?>
285 + <?php
286 + // translators: %1$s is opening anchor tag and %2$s is closing anchor tag
287 + printf(esc_html__('When the "Enable defer on processed JavaScript files" option is enabled, JavaScript and CSS files will not be loaded from the CDN due to %1$scompatibility%2$s reasons.', 'wp-optimize'), '<a target="_blank" href="https://www.chromestatus.com/feature/5718547946799104">', '</a>');
288 + esc_html_e('However, you can define a CDN Domain below, in order to use it for all of the static assets "inside" your CSS and JS files.', 'wp-optimize');
289 + ?>
282 290 </p>
283 291
284 292 <h3><?php esc_html_e('Your CDN domain', 'wp-optimize'); ?></h3>
285 293 <div class="wpo-fieldgroup">
@@ -311,31 +319,29 @@
311 319 <p class="wpo_min-bold-green wpo_min-rowintro">
312 320 <?php esc_html_e('If you force this, your JS files may not load for certain slow internet users on Google Chrome.', 'wp-optimize'); ?>
313 321 </p>
314 322 <fieldset>
315 - <label for="cdn_force">
316 - <input
317 - name="cdn_force"
318 - type="checkbox"
319 - id="cdn_force"
320 - value="1"
321 - <?php echo checked($wpo_minify_options['cdn_force']); ?>
322 - >
323 - <?php esc_html_e('I know what I\'m doing...', 'wp-optimize'); ?>
324 - <span tabindex="0" data-tooltip="<?php esc_attr_e('Load my JS files from the CDN, even when "defer for Pagespeed Insights" is enabled', 'wp-optimize');?>"><span class="dashicons dashicons-editor-help"></span> </span>
325 - </label>
323 + <div class="wpo-fieldgroup__subgroup">
324 + <label for="cdn_force">
325 + <input
326 + name="cdn_force"
327 + type="checkbox"
328 + id="cdn_force"
329 + value="1"
330 + <?php echo checked($wpo_minify_options['cdn_force']); ?>
331 + >
332 + <?php esc_html_e('I know what I\'m doing...', 'wp-optimize'); ?>
333 + </label>
334 + <span tabindex="0" class="wpo-tooltip" data-tooltip="<?php esc_attr_e('Load my JS files from the CDN, even when "defer for Pagespeed Insights" is enabled', 'wp-optimize');?>"><span class="dashicons dashicons-editor-help"></span> </span>
335 + </div>
326 336 </fieldset>
327 337 </div>
328 338 <?php endif; ?>
329 339
330 - <p class="submit">
331 - <input
332 - class="wp-optimize-save-minify-settings button button-primary"
333 - type="submit"
334 - value="<?php esc_attr_e('Save settings', 'wp-optimize'); ?>"
335 - >
336 - <img class="wpo_spinner" src="<?php echo esc_url(admin_url('images/spinner-2x.gif')); ?>" alt="...">
340 + <div class="wpo-save-btn-container">
341 + <input class="wp-optimize-save-minify-settings button button-primary" type="submit" value="<?php esc_attr_e('Save settings', 'wp-optimize'); ?>">
342 + <img class="wpo_spinner" src="<?php echo esc_url(admin_url('images/spinner-2x.gif')); // phpcs:ignore PluginCheck.CodeAnalysis.ImageFunctions.NonEnqueuedImage -- N/A ?>" alt="...">
337 343 <span class="save-done dashicons dashicons-yes display-none"></span>
338 - </p>
344 + </div>
339 345 <input type="hidden" name="minify_advanced_tab" value="1">
340 346 </form>
341 347 </div>