Version Description
= v160416 =
Requires WordPress v4.2+.
Download this release
Release Info
Developer | raamdev |
Plugin | Comet Cache |
Version | 160917 |
Comparing to | |
See all releases |
Code changes from version 160706 to 160917
- CHANGELOG.md +19 -0
- comet-cache.php +1 -1
- readme.txt +23 -3
- src/client-s/css/admin-bar.min.css +1 -1
- src/client-s/css/menu-pages.min.css +1 -1
- src/client-s/js/admin-bar.js +134 -0
- src/client-s/js/admin-bar.min.js +1 -0
- src/includes/classes/Actions.php +57 -7
- src/includes/classes/MenuPage.php +0 -2
- src/includes/classes/MenuPageOptions.php +52 -13
- src/includes/classes/Plugin.php +28 -14
- src/includes/classes/VsUpgrades.php +18 -5
- src/includes/stub.php +1 -1
- src/includes/templates/{advanced-cache.txt → advanced-cache.x-php} +0 -0
- src/includes/traits/Plugin/AdminBarUtils.php +181 -0
- src/includes/traits/Plugin/InstallUtils.php +16 -10
- src/includes/traits/Plugin/MenuPageUtils.php +1 -7
- src/includes/traits/Plugin/OptionUtils.php +14 -6
- src/includes/traits/Plugin/UpdateUtils.php +6 -17
- src/includes/traits/Plugin/WcpSettingUtils.php +9 -4
- src/includes/traits/Plugin/WcpUpdaterUtils.php +3 -1
- src/vendor/autoload.php +1 -1
- src/vendor/composer/autoload_classmap.php +1 -0
- src/vendor/composer/autoload_real.php +3 -3
- src/vendor/composer/installed.json +15 -14
- src/vendor/websharks/sharkicons/README.md +0 -154
- src/vendor/websharks/wp-php-rv/CHANGELOG.md +21 -0
- src/vendor/websharks/wp-php-rv/README.md +0 -97
- src/vendor/websharks/wp-php-rv/src/includes/functions/.load.php +1 -0
- src/vendor/websharks/wp-php-rv/src/includes/functions/checks.php +115 -41
- src/vendor/websharks/wp-php-rv/src/includes/functions/notices.php +90 -41
- src/vendor/websharks/wp-php-rv/src/includes/functions/utils.php +101 -0
CHANGELOG.md
CHANGED
@@ -1,3 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
= v160706 =
|
2 |
|
3 |
- **New Feature! Apache Optimizations.** This release includes a completely new option panel for Apache Performance Tuning. Current options for Apache tuning include GZIP Compression, Leverage Browser Caching, Enforce Canonical URLs, and Send Access-Control-Allow-Origin Header (for Static CDN Filters). These options automatically add or remove from your `.htaccess` file the appropriate configuration based on the options you enable or disable (all options are disabled by default, so your `.htaccess` file is not modified unless you say so). If you prefer to update your `.htaccess` file manually, the necessary configuration can be viewed beneath each option. Props @jaswsinc, @renzms. See [Issue #789](https://github.com/websharks/comet-cache/issues/789).
|
1 |
+
= v160917 =
|
2 |
+
|
3 |
+
- **New Feature** (Lite): The Clear Cache button is now available in the Admin Toolbar for the Lite version of Comet Cache.
|
4 |
+
- **New Feature** (Pro): Comet Cache Pro is now fully compatible with [WordPress Automatic Background Updates](https://codex.wordpress.org/Configuring_Automatic_Background_Updates#Plugin_.26_Theme_Updates_via_Filter). If you enable automatic background updates for plugins, and you save valid Comet Cache Pro License Credentials in the _Comet Cache Pro → Plugin Options → Update Credentials_ panel, you will automatically receive Pro plugin updates. Props @jaswsinc. See [Issue #289](https://github.com/websharks/comet-cache/issues/289).
|
5 |
+
- **Bug Fix**: In some scenarios Comet Cache might produce a false-positive "Warning: mkdir(): File exists" message when checking if the cache directory exists. Comet Cache now calls `clearstatcache()` and uses `file_exists()` instead of `is_dir()` to help make this check more robust. See [Issue #786](https://github.com/websharks/comet-cache/issues/786).
|
6 |
+
- **Bug Fix**: Fixed a bug where the Comet Cache PHP requirements check would fail and produce a fatal error when upgrading from a version of Comet Cache that did not require an extension that is now required by newer releases. This would occur when, for example, the required PHP `mbstring` extension was missing. Props @jaswsinc for finding the bug. See [Issue #817](https://github.com/websharks/comet-cache/issues/817).
|
7 |
+
- **Bug Fix**: Fixed a bug where upgrading from v160521 would result in the Client-Side Cache option being reset to the default (disabled). If you enabled the Client-Side Cache at some point, now is a good time to double-check that it's still enabled. This bug fix also improves the reliability of all version upgrade routines that Comet Cache runs during upgrades. See [Issue #807](https://github.com/websharks/comet-cache/issues/807).
|
8 |
+
- **Compatibility / Bug Fix**: The automatic Clear Cache routines that cleared the entire cache automatically whenever _WordPress Dashboard → Settings → General_ was updated, were being too aggressive and not taking into consideration other plugins that might also be using the same `options-general.php` URL. As a result, the entire cache was being unnecessarily cleared when the settings for those other plugins were saved. Props to @futtta from Autoptimize for reporting. See [Issue #825](https://github.com/websharks/comet-cache/issues/825).
|
9 |
+
- **UI Enhancement:** Adjusted option page font styles for WordPress v4.6 to better match existing style. See [Issue #271](https://github.com/websharks/comet-cache-pro/pull/271).
|
10 |
+
- **ManageWP Compatibility** (Pro): Comet Cache Pro is now compatible with ManageWP, a service that allows remote management of multiple WordPress sites. Comet Cache Pro Plugin Updates will now appear in the ManageWP dashboard and, assuming you have saved valid license credentials in _Dashboard → Comet Cache Pro → Plugin Options → Update Credentials_, you will be able to upgrade Comet Cache Pro remotely from the ManageWP Dashboard. Props @jaswsinc. See [Issue #465](https://github.com/websharks/comet-cache/issues/465).
|
11 |
+
- **InfiniteWP Compatibility** (Pro): Comet Cache Pro is now compatible with InfiniteWP, an application that allows you to manage multiple WordPress sites from a single location. Comet Cache Pro Plugin Updates will now appear in the InfiniteWP dashboard and, assuming you have saved valid license credentials in _Dashboard → Comet Cache Pro → Plugin Options → Update Credentials_, you will be able to upgrade Comet Cache Pro remotely from the InfiniteWP Dashboard. See [Issue #394](https://github.com/websharks/comet-cache/issues/394).
|
12 |
+
- **Rewritten Pro Plugin Updater**: The Comet Cache Pro Plugin Updater has been redesigned to use the built-in WordPress plugin updater system. When a Comet Cache Pro update is available, it now appears in the WordPress Updates section and in the Plugins list, like other WordPress plugins and can be updated normally like other WordPress plugins, as long as you have saved valid Comet Cache Pro license details in the new "Update Credentials" options panel. Props @jaswsinc. See [Issue #272](https://github.com/websharks/comet-cache-pro/issues/272).
|
13 |
+
- **Code Style**: The `WP_CACHE` line that gets inserted into the `wp-config.php` file to enable caching now follows the [WordPress PHP Code Standards](https://make.wordpress.org/core/handbook/best-practices/coding-standards/php/). Props @szepeviktor. See [Issue #799](https://github.com/websharks/comet-cache/pull/799).
|
14 |
+
- **Compatibility** (Pro): When the Autoptimize plugin is active, the Comet Cache Pro HTML Compressor panel now shows a friendly notice explaining that both the HTML Compressor and Autoptimize should not be enabled at the same time because they both address the same performance improvements. The rest of Comet Cache works great alongside Autoptimize and whether you use the HTML Compressor or Autoptimize is a matter of preference. Props to @futtta from Autoptimize for the continued collaboration.
|
15 |
+
|
16 |
+
= v160709 =
|
17 |
+
|
18 |
+
- **Bug Fix** (Pro): Fixed a bug in the Auto-Cache Engine that was introduced by the previous release (v160706). The bug produced an error whenever the Auto-Cache Engine ran: "PHP Fatal error: Call to undefined method applyWpFilters()". This had no visible affect on the front-end of the site or in the WordPress Dashboard, but it prevented the Auto-Cache Engine from working behind the scenes. Props @Peter-FB for reporting. See [Issue #795](https://github.com/websharks/comet-cache/issues/795).
|
19 |
+
|
20 |
= v160706 =
|
21 |
|
22 |
- **New Feature! Apache Optimizations.** This release includes a completely new option panel for Apache Performance Tuning. Current options for Apache tuning include GZIP Compression, Leverage Browser Caching, Enforce Canonical URLs, and Send Access-Control-Allow-Origin Header (for Static CDN Filters). These options automatically add or remove from your `.htaccess` file the appropriate configuration based on the options you enable or disable (all options are disabled by default, so your `.htaccess` file is not modified unless you say so). If you prefer to update your `.htaccess` file manually, the necessary configuration can be viewed beneath each option. Props @jaswsinc, @renzms. See [Issue #789](https://github.com/websharks/comet-cache/issues/789).
|
comet-cache.php
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
<?php
|
2 |
/*
|
3 |
-
Version:
|
4 |
Text Domain: comet-cache
|
5 |
Plugin Name: Comet Cache
|
6 |
Network: true
|
1 |
<?php
|
2 |
/*
|
3 |
+
Version: 160917
|
4 |
Text Domain: comet-cache
|
5 |
Plugin Name: Comet Cache
|
6 |
Network: true
|
readme.txt
CHANGED
@@ -1,14 +1,14 @@
|
|
1 |
=== Comet Cache ===
|
2 |
|
3 |
-
Stable tag:
|
4 |
Requires at least: 4.2
|
5 |
-
Tested up to: 4.
|
6 |
Text Domain: comet-cache
|
7 |
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
11 |
-
Contributors: WebSharks, JasWSInc, raamdev, renzms, KristineDS
|
12 |
Donate link: http://websharks-inc.com/r/wp-theme-plugin-donation/
|
13 |
Tags: cache, speed, performance, fast, caching, advanced cache, static, client-side cache, rss cache, feed cache, gzip compression, page cache
|
14 |
|
@@ -58,6 +58,7 @@ The Comet Cache plugin uses configuration options that you select from the optio
|
|
58 |
- Cache Statistics and Charts to analyze statistics about the page cache, HTML Compressor cache, PHP OPCache, and server health.
|
59 |
- Apache Optimizations to enable web server GZIP Compression, Leverage Browser Caching, Enforce Canonical URLs, and more.
|
60 |
- An Automatic Updater to update Comet Cache Pro from your WordPress Dashboard.
|
|
|
61 |
- Rockstar support for all Comet Cache features.
|
62 |
|
63 |
TIP: you can preview Pro features in the free version by clicking the "Preview Pro Features" link at the top of your Comet Cache options.
|
@@ -337,6 +338,25 @@ Requires WordPress v4.2+.
|
|
337 |
|
338 |
== Changelog ==
|
339 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
340 |
= v160706 =
|
341 |
|
342 |
- **New Feature! Apache Optimizations.** This release includes a completely new option panel for Apache Performance Tuning. Current options for Apache tuning include GZIP Compression, Leverage Browser Caching, Enforce Canonical URLs, and Send Access-Control-Allow-Origin Header (for Static CDN Filters). These options automatically add or remove from your `.htaccess` file the appropriate configuration based on the options you enable or disable (all options are disabled by default, so your `.htaccess` file is not modified unless you say so). If you prefer to update your `.htaccess` file manually, the necessary configuration can be viewed beneath each option. Props @jaswsinc, @renzms. See [Issue #789](https://github.com/websharks/comet-cache/issues/789).
|
1 |
=== Comet Cache ===
|
2 |
|
3 |
+
Stable tag: 160917
|
4 |
Requires at least: 4.2
|
5 |
+
Tested up to: 4.7-alpha
|
6 |
Text Domain: comet-cache
|
7 |
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
11 |
+
Contributors: WebSharks, JasWSInc, raamdev, renzms, KristineDS
|
12 |
Donate link: http://websharks-inc.com/r/wp-theme-plugin-donation/
|
13 |
Tags: cache, speed, performance, fast, caching, advanced cache, static, client-side cache, rss cache, feed cache, gzip compression, page cache
|
14 |
|
58 |
- Cache Statistics and Charts to analyze statistics about the page cache, HTML Compressor cache, PHP OPCache, and server health.
|
59 |
- Apache Optimizations to enable web server GZIP Compression, Leverage Browser Caching, Enforce Canonical URLs, and more.
|
60 |
- An Automatic Updater to update Comet Cache Pro from your WordPress Dashboard.
|
61 |
+
- Compatibility with ManageWP and InfiniteWP.
|
62 |
- Rockstar support for all Comet Cache features.
|
63 |
|
64 |
TIP: you can preview Pro features in the free version by clicking the "Preview Pro Features" link at the top of your Comet Cache options.
|
338 |
|
339 |
== Changelog ==
|
340 |
|
341 |
+
= v160917 =
|
342 |
+
|
343 |
+
- **New Feature** (Lite): The Clear Cache button is now available in the Admin Toolbar for the Lite version of Comet Cache.
|
344 |
+
- **New Feature** (Pro): Comet Cache Pro is now fully compatible with [WordPress Automatic Background Updates](https://codex.wordpress.org/Configuring_Automatic_Background_Updates#Plugin_.26_Theme_Updates_via_Filter). If you enable automatic background updates for plugins, and you save valid Comet Cache Pro License Credentials in the _Comet Cache Pro → Plugin Options → Update Credentials_ panel, you will automatically receive Pro plugin updates. Props @jaswsinc. See [Issue #289](https://github.com/websharks/comet-cache/issues/289).
|
345 |
+
- **Bug Fix**: In some scenarios Comet Cache might produce a false-positive "Warning: mkdir(): File exists" message when checking if the cache directory exists. Comet Cache now calls `clearstatcache()` and uses `file_exists()` instead of `is_dir()` to help make this check more robust. See [Issue #786](https://github.com/websharks/comet-cache/issues/786).
|
346 |
+
- **Bug Fix**: Fixed a bug where the Comet Cache PHP requirements check would fail and produce a fatal error when upgrading from a version of Comet Cache that did not require an extension that is now required by newer releases. This would occur when, for example, the required PHP `mbstring` extension was missing. Props @jaswsinc for finding the bug. See [Issue #817](https://github.com/websharks/comet-cache/issues/817).
|
347 |
+
- **Bug Fix**: Fixed a bug where upgrading from v160521 would result in the Client-Side Cache option being reset to the default (disabled). If you enabled the Client-Side Cache at some point, now is a good time to double-check that it's still enabled. This bug fix also improves the reliability of all version upgrade routines that Comet Cache runs during upgrades. See [Issue #807](https://github.com/websharks/comet-cache/issues/807).
|
348 |
+
- **Compatibility / Bug Fix**: The automatic Clear Cache routines that cleared the entire cache automatically whenever _WordPress Dashboard → Settings → General_ was updated, were being too aggressive and not taking into consideration other plugins that might also be using the same `options-general.php` URL. As a result, the entire cache was being unnecessarily cleared when the settings for those other plugins were saved. Props to @futtta from Autoptimize for reporting. See [Issue #825](https://github.com/websharks/comet-cache/issues/825).
|
349 |
+
- **UI Enhancement**: Adjusted option page font styles for WordPress v4.6 to better match existing style. See [Issue #271](https://github.com/websharks/comet-cache-pro/pull/271).
|
350 |
+
- **ManageWP Compatibility** (Pro): Comet Cache Pro is now compatible with ManageWP, a service that allows remote management of multiple WordPress sites. Comet Cache Pro Plugin Updates will now appear in the ManageWP dashboard and, assuming you have saved valid license credentials in _Dashboard → Comet Cache Pro → Plugin Options → Update Credentials_, you will be able to upgrade Comet Cache Pro remotely from the ManageWP Dashboard. Props @jaswsinc. See [Issue #465](https://github.com/websharks/comet-cache/issues/465).
|
351 |
+
- **InfiniteWP Compatibility** (Pro): Comet Cache Pro is now compatible with InfiniteWP, an application that allows you to manage multiple WordPress sites from a single location. Comet Cache Pro Plugin Updates will now appear in the InfiniteWP dashboard and, assuming you have saved valid license credentials in _Dashboard → Comet Cache Pro → Plugin Options → Update Credentials_, you will be able to upgrade Comet Cache Pro remotely from the InfiniteWP Dashboard. See [Issue #394](https://github.com/websharks/comet-cache/issues/394).
|
352 |
+
- **Rewritten Pro Plugin Updater**: The Comet Cache Pro Plugin Updater has been redesigned to use the built-in WordPress plugin updater system. When a Comet Cache Pro update is available, it now appears in the WordPress Updates section and in the Plugins list, like other WordPress plugins and can be updated normally like other WordPress plugins, as long as you have saved valid Comet Cache Pro license details in the new "Update Credentials" options panel. Props @jaswsinc. See [Issue #272](https://github.com/websharks/comet-cache-pro/issues/272).
|
353 |
+
- **Code Style**: The `WP_CACHE` line that gets inserted into the `wp-config.php` file to enable caching now follows the [WordPress PHP Code Standards](https://make.wordpress.org/core/handbook/best-practices/coding-standards/php/). Props @szepeviktor. See [Issue #799](https://github.com/websharks/comet-cache/pull/799).
|
354 |
+
- **Compatibility** (Pro): When the Autoptimize plugin is active, the Comet Cache Pro HTML Compressor panel now shows a friendly notice explaining that both the HTML Compressor and Autoptimize should not be enabled at the same time because they both address the same performance improvements. The rest of Comet Cache works great alongside Autoptimize and whether you use the HTML Compressor or Autoptimize is a matter of preference. Props to @futtta from Autoptimize for the continued collaboration.
|
355 |
+
|
356 |
+
= v160709 =
|
357 |
+
|
358 |
+
- **Bug Fix** (Pro): Fixed a bug in the Auto-Cache Engine that was introduced by the previous release (v160706). The bug produced an error whenever the Auto-Cache Engine ran: "PHP Fatal error: Call to undefined method applyWpFilters()". This had no visible affect on the front-end of the site or in the WordPress Dashboard, but it prevented the Auto-Cache Engine from working behind the scenes. Props @Peter-FB for reporting. See [Issue #795](https://github.com/websharks/comet-cache/issues/795).
|
359 |
+
|
360 |
= v160706 =
|
361 |
|
362 |
- **New Feature! Apache Optimizations.** This release includes a completely new option panel for Apache Performance Tuning. Current options for Apache tuning include GZIP Compression, Leverage Browser Caching, Enforce Canonical URLs, and Send Access-Control-Allow-Origin Header (for Static CDN Filters). These options automatically add or remove from your `.htaccess` file the appropriate configuration based on the options you enable or disable (all options are disabled by default, so your `.htaccess` file is not modified unless you say so). If you prefer to update your `.htaccess` file manually, the necessary configuration can be viewed beneath each option. Props @jaswsinc, @renzms. See [Issue #789](https://github.com/websharks/comet-cache/issues/789).
|
src/client-s/css/admin-bar.min.css
CHANGED
@@ -1,2 +1,2 @@
|
|
1 |
-
|
2 |
|
1 |
+
@font-face{font-family:sharkicons;src:url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.eot?v160221");src:url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.eot?#iefix&v160221") format("embedded-opentype"),url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.ttf?v160221") format("truetype"),url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.woff?v160221") format("woff"),url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.svg?v160221#sharkicons") format("svg");font-weight:normal;font-style:normal}.comet_cache-admin-bar-animation-spin{-webkit-animation-duration:0.75s;-moz-animation-duration:0.75s;animation-duration:0.75s;-webkit-animation-fill-mode:both;-moz-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:linear;-moz-animation-timing-function:linear;animation-timing-function:linear;-webkit-animation-iteration-count:infinite;-moz-animation-iteration-count:infinite;animation-iteration-count:infinite;-webkit-animation-name:comet_cache-admin-bar-animation-spin;-moz-animation-name:comet_cache-admin-bar-animation-spin;animation-name:comet_cache-admin-bar-animation-spin}@-webkit-keyframes comet_cache-admin-bar-animation-spin{0%{-webkit-transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg)}}@-moz-keyframes comet_cache-admin-bar-animation-spin{0%{-moz-transform:rotate(0deg)}100%{-moz-transform:rotate(360deg)}}@keyframes comet_cache-admin-bar-animation-spin{0%{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);-ms-transform:rotate(0deg);-o-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);-ms-transform:rotate(360deg);-o-transform:rotate(360deg);transform:rotate(360deg)}}.comet_cache-admin-bar-animation-zoom-in-down{-webkit-animation-duration:0.75s;-moz-animation-duration:0.75s;animation-duration:0.75s;-webkit-animation-fill-mode:both;-moz-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-name:comet_cache-admin-bar-animation-zoom-in-down;-moz-animation-name:comet_cache-admin-bar-animation-zoom-in-down;animation-name:comet_cache-admin-bar-animation-zoom-in-down}@-webkit-keyframes comet_cache-admin-bar-animation-zoom-in-down{from{-webkit-transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -1000px, 0);-webkit-animation-timing-function:cubic-bezier(0.55, 0.055, 0.675, 0.19);opacity:0}60%{-webkit-transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);-webkit-animation-timing-function:cubic-bezier(0.175, 0.885, 0.32, 1);opacity:1}}@-moz-keyframes comet_cache-admin-bar-animation-zoom-in-down{from{-moz-transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -1000px, 0);-moz-animation-timing-function:cubic-bezier(0.55, 0.055, 0.675, 0.19);opacity:0}60%{-moz-transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);-moz-animation-timing-function:cubic-bezier(0.175, 0.885, 0.32, 1);opacity:1}}@keyframes comet_cache-admin-bar-animation-zoom-in-down{from{-webkit-transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -1000px, 0);-moz-transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -1000px, 0);-ms-transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -1000px, 0);-o-transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -1000px, 0);transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -1000px, 0);-webkit-animation-timing-function:cubic-bezier(0.55, 0.055, 0.675, 0.19);-moz-animation-timing-function:cubic-bezier(0.55, 0.055, 0.675, 0.19);animation-timing-function:cubic-bezier(0.55, 0.055, 0.675, 0.19);opacity:0}60%{-webkit-transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);-moz-transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);-ms-transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);-o-transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);-webkit-animation-timing-function:cubic-bezier(0.175, 0.885, 0.32, 1);-moz-animation-timing-function:cubic-bezier(0.175, 0.885, 0.32, 1);animation-timing-function:cubic-bezier(0.175, 0.885, 0.32, 1);opacity:1}}.comet_cache-admin-bar-animation-zoom-out-up{-webkit-animation-duration:0.15s;-moz-animation-duration:0.15s;animation-duration:0.15s;-webkit-animation-fill-mode:both;-moz-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-name:comet_cache-admin-bar-animation-zoom-out-up;-moz-animation-name:comet_cache-admin-bar-animation-zoom-out-up;animation-name:comet_cache-admin-bar-animation-zoom-out-up}@-webkit-keyframes comet_cache-admin-bar-animation-zoom-out-up{40%{-webkit-transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);-webkit-animation-timing-function:cubic-bezier(0.55, 0.055, 0.675, 0.19);opacity:1}100%{-webkit-transform-origin:center bottom;-webkit-transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -2000px, 0);-webkit-animation-timing-function:cubic-bezier(0.175, 0.885, 0.32, 1);opacity:0}}@-moz-keyframes comet_cache-admin-bar-animation-zoom-out-up{40%{-moz-transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);-moz-animation-timing-function:cubic-bezier(0.55, 0.055, 0.675, 0.19);opacity:1}100%{-moz-transform-origin:center bottom;-moz-transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -2000px, 0);-moz-animation-timing-function:cubic-bezier(0.175, 0.885, 0.32, 1);opacity:0}}@keyframes comet_cache-admin-bar-animation-zoom-out-up{40%{-webkit-transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);-moz-transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);-ms-transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);-o-transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);transform:scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);-webkit-animation-timing-function:cubic-bezier(0.55, 0.055, 0.675, 0.19);-moz-animation-timing-function:cubic-bezier(0.55, 0.055, 0.675, 0.19);animation-timing-function:cubic-bezier(0.55, 0.055, 0.675, 0.19);opacity:1}100%{-webkit-transform-origin:center bottom;-moz-transform-origin:center bottom;-ms-transform-origin:center bottom;-o-transform-origin:center bottom;transform-origin:center bottom;-webkit-transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -2000px, 0);-moz-transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -2000px, 0);-ms-transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -2000px, 0);-o-transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -2000px, 0);transform:scale3d(0.1, 0.1, 0.1) translate3d(0, -2000px, 0);-webkit-animation-timing-function:cubic-bezier(0.175, 0.885, 0.32, 1);-moz-animation-timing-function:cubic-bezier(0.175, 0.885, 0.32, 1);animation-timing-function:cubic-bezier(0.175, 0.885, 0.32, 1);opacity:0}}#wp-admin-bar-comet_cache-wipe>a::after,#wp-admin-bar-comet_cache-clear>a::after{border:0;padding:0;content:' ';width:16px;height:16px;line-height:16px;vertical-align:middle;margin:-3px 0 0 5px;display:inline-block}#wp-admin-bar-comet_cache-wipe.-wipe>a::after,#wp-admin-bar-comet_cache-clear.-wipe>a::after{content:url("../images/wipe.png")}#wp-admin-bar-comet_cache-wipe.-clear>a::after,#wp-admin-bar-comet_cache-clear.-clear>a::after{content:url("../images/clear.png")}#wp-admin-bar-comet_cache-wipe.-processing>a::after,#wp-admin-bar-comet_cache-clear.-processing>a::after{-webkit-animation-duration:0.75s;-moz-animation-duration:0.75s;animation-duration:0.75s;-webkit-animation-fill-mode:both;-moz-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:linear;-moz-animation-timing-function:linear;animation-timing-function:linear;-webkit-animation-iteration-count:infinite;-moz-animation-iteration-count:infinite;animation-iteration-count:infinite;-webkit-animation-name:comet_cache-admin-bar-animation-spin;-moz-animation-name:comet_cache-admin-bar-animation-spin;animation-name:comet_cache-admin-bar-animation-spin;content:url("../images/spinner.png")}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper,#wp-admin-bar-comet_cache-clear-options-wrapper .-container,#wp-admin-bar-comet_cache-clear-options-wrapper .-container>div{margin:0 !important;padding:0 !important;display:block !important;white-space:normal !important;width:100% !important;min-width:100% !important;height:auto !important;line-height:normal !important;box-sizing:border-box !important}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper{padding:1em !important}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper .-container *{margin:0;padding:0;width:auto;height:auto;position:static;line-height:normal;box-sizing:border-box}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper .-container .-label{margin:0 0 1em}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper .-container .-label::after{border:0;padding:0;width:16px;height:16px;float:right;vertical-align:middle;display:inline-block;content:url("../images/clear.png")}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper .-container .-label .-text{opacity:0.75}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper .-container .-label.-processing::after{-webkit-animation-duration:0.75s;-moz-animation-duration:0.75s;animation-duration:0.75s;-webkit-animation-fill-mode:both;-moz-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:linear;-moz-animation-timing-function:linear;animation-timing-function:linear;-webkit-animation-iteration-count:infinite;-moz-animation-iteration-count:infinite;animation-iteration-count:infinite;-webkit-animation-name:comet_cache-admin-bar-animation-spin;-moz-animation-name:comet_cache-admin-bar-animation-spin;animation-name:comet_cache-admin-bar-animation-spin;content:url("../images/spinner.png")}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper .-container .-options>li>a::before{padding-right:.5em;text-align:center;width:1.28571429em}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper .-container .-options .-home-url-only>a::before{font:normal normal normal 14px/1 sharkicons;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;font-smoothing:antialiased;display:inline-block;font-size:inherit;text-decoration:inherit;text-transform:none;content:""}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper .-container .-options .-current-url-only>a::before{font:normal normal normal 14px/1 sharkicons;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;font-smoothing:antialiased;display:inline-block;font-size:inherit;text-decoration:inherit;text-transform:none;content:""}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper .-container .-options .-specific-url-only>a::before{font:normal normal normal 14px/1 sharkicons;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;font-smoothing:antialiased;display:inline-block;font-size:inherit;text-decoration:inherit;text-transform:none;content:""}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper .-container .-options .-opcache-only>a::before{font:normal normal normal 14px/1 sharkicons;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;font-smoothing:antialiased;display:inline-block;font-size:inherit;text-decoration:inherit;text-transform:none;content:""}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper .-container .-options .-cdn-only>a::before{font:normal normal normal 14px/1 sharkicons;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;font-smoothing:antialiased;display:inline-block;font-size:inherit;text-decoration:inherit;text-transform:none;content:""}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper .-container .-options .-transients-only>a::before{font:normal normal normal 14px/1 sharkicons;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;font-smoothing:antialiased;display:inline-block;font-size:inherit;text-decoration:inherit;text-transform:none;content:""}#wp-admin-bar-comet_cache-clear-options-wrapper.-wrapper .-container .-spacer{min-width:145px}#wp-admin-bar-comet_cache-clear-options{border-left:1px solid #585858;border-right:1px solid #585858}#wp-admin-bar-comet_cache-clear-options>a::after{font:normal normal normal 14px/1 sharkicons;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;font-smoothing:antialiased;display:inline-block;font-size:inherit;text-decoration:inherit;text-transform:none;content:""}#wp-admin-bar-comet_cache-clear-options .-wrapper .-container .-spacer{min-width:145px}.comet_cache-ajax-response{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;display:none;left:50%;top:100px;z-index:10000;position:fixed;width:700px;height:auto;min-height:64px;padding:15px;text-align:center;outline:none;cursor:pointer;border-radius:5px;box-sizing:border-box;margin:0 0 0 -350px;background:#15181b;color:#fff;box-shadow:0 0 5px 0 #23282d}.comet_cache-ajax-response::after{font:normal normal normal 14px/1 sharkicons;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;font-smoothing:antialiased;display:inline-block;font-size:inherit;text-decoration:inherit;text-transform:none;content:""}.comet_cache-ajax-response:hover,.comet_cache-ajax-response.-hovered{background-color:#000}.comet_cache-ajax-response.-wipe::before,.comet_cache-ajax-response.-clear::before{left:0;top:0;width:64px;height:64px;position:absolute}.comet_cache-ajax-response.-wipe::before{content:url("../images/wipe-response.png")}.comet_cache-ajax-response.-clear::before{content:url("../images/clear-response.png")}.comet_cache-ajax-response::after{top:5px;right:8px;opacity:0.5;font-size:120%;position:absolute}.comet_cache-ajax-response p{margin:0;padding:0;opacity:0.35;font:15px/1.2em sans-serif}.comet_cache-ajax-response p:first-child{opacity:1}.comet_cache-ajax-response code{border-radius:3px;padding:1px 3px;color:#000;background:#eee}
|
2 |
|
src/client-s/css/menu-pages.min.css
CHANGED
@@ -1,2 +1,2 @@
|
|
1 |
-
@font-face{font-family:sharkicons;src:url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.eot?v160221");src:url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.eot?#iefix&v160221") format("embedded-opentype"),url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.ttf?v160221") format("truetype"),url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.woff?v160221") format("woff"),url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.svg?v160221#sharkicons") format("svg");font-weight:normal;font-style:normal}.si::before{font:normal normal normal 14px/1 sharkicons;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;font-smoothing:antialiased;display:inline-block;font-size:inherit;text-decoration:inherit;text-transform:none}.si-broom::before{content:""}.si-comment-mail-one::before{content:""}.si-comment-mail::before{content:""}.si-s2member::before{content:""}.si-websharks::before{content:""}.si-wp-kb-articles::before{content:""}.si-zencache-logo::before{content:""}.si-zencache::before{content:""}.si-wp-sharks::before{content:""}.si-wp-sharks-fin::before{content:""}.si-comet-cache::before{content:""}.si-comet-cache-logo::before{content:""}.si-comet-cache-comet::before{content:""}.si-feat-watch::before{content:""}.si-feat-server::before{content:""}.si-feat-layers::before{content:""}.si-feat-box::before{content:""}.si-feat-ellipsis::before{content:""}.si-typi-group::before{content:""}.si-enty-bookmark::before{content:""}.si-enty-bookmarks::before{content:""}.si-enty-open-book::before{content:""}.si-enty-archive::before{content:""}.si-enty-area-graph::before{content:""}.si-enty-bucket::before{content:""}.si-enty-colors::before{content:""}.si-enty-copy::before{content:""}.si-enty-drive::before{content:""}.si-enty-feather::before{content:""}.si-enty-gauge::before{content:""}.si-enty-hand::before{content:""}.si-enty-lab-flask::before{content:""}.si-enty-mask::before{content:""}.si-enty-medal::before{content:""}.si-enty-exclamation::before{content:""}.si-enty-palette::before{content:""}.si-enty-ruler::before{content:""}.si-enty-shop::before{content:""}.si-enty-basket::before{content:""}.si-enty-cart::before{content:""}.si-enty-traffic-cone::before{content:""}.si-enty-tree::before{content:""}.si-enty-trophy::before{content:""}.si-enty-v-card::before{content:""}.si-enty-google-hangouts::before{content:""}.si-eleg-line-graph::before{content:""}.si-eleg-male::before{content:""}.si-eleg-female::before{content:""}.si-eleg-atom::before{content:""}.si-broc-cart::before{content:""}.si-broc-crap::before{content:""}.si-broc-atom::before{content:""}.si-icom-headphones::before{content:""}.si-icom-barcode::before{content:""}.si-icom-user::before{content:""}.si-icom-users::before{content:""}.si-icom-user-plus::before{content:""}.si-icom-user-minus::before{content:""}.si-icom-user-check::before{content:""}.si-icom-user-tie::before{content:""}.si-icom-key::before{content:""}.si-icom-key2::before{content:""}.si-icom-happy::before{content:""}.si-icom-happy2::before{content:""}.si-icom-smile::before{content:""}.si-icom-smile2::before{content:""}.si-icom-tongue::before{content:""}.si-icom-tongue2::before{content:""}.si-icom-sad::before{content:""}.si-icom-sad2::before{content:""}.si-icom-wink::before{content:""}.si-icom-wink2::before{content:""}.si-icom-grin::before{content:""}.si-icom-grin2::before{content:""}.si-icom-cool::before{content:""}.si-icom-cool2::before{content:""}.si-icom-angry::before{content:""}.si-icom-angry2::before{content:""}.si-icom-evil::before{content:""}.si-icom-evil2::before{content:""}.si-icom-shocked::before{content:""}.si-icom-shocked2::before{content:""}.si-icom-baffled::before{content:""}.si-icom-baffled2::before{content:""}.si-icom-confused::before{content:""}.si-icom-confused2::before{content:""}.si-icom-neutral::before{content:""}.si-icom-neutral2::before{content:""}.si-icom-hipster::before{content:""}.si-icom-hipster2::before{content:""}.si-icom-wondering::before{content:""}.si-icom-wondering2::before{content:""}.si-icom-sleepy::before{content:""}.si-icom-sleepy2::before{content:""}.si-icom-frustrated::before{content:""}.si-icom-frustrated2::before{content:""}.si-icom-crying::before{content:""}.si-icom-crying2::before{content:""}.si-icom-spell-check::before{content:""}.si-icom-command-key::before{content:""}.si-icom-shift-key::before{content:""}.si-icom-control-key::before{content:""}.si-icom-option-key::before{content:""}.si-icom-wordpress::before{content:""}.si-icom-wordpress-square::before{content:""}.si-icom-yahoo::before{content:""}.si-icom-linux::before{content:""}.si-icom-finder::before{content:""}.si-icom-android::before{content:""}.si-icom-reddit::before{content:""}.si-icom-paypal::before{content:""}.si-icom-git::before{content:""}.si-octi-alignment-align::before{content:""}.si-octi-alignment-aligned-to::before{content:""}.si-octi-alignment-unalign::before{content:""}.si-octi-bookmark::before{content:""}.si-octi-broadcast::before{content:""}.si-octi-browser::before{content:""}.si-octi-checklist::before{content:""}.si-octi-circuit-board::before{content:""}.si-octi-clippy::before{content:""}.si-octi-cloud-download::before{content:""}.si-octi-cloud-upload::before{content:""}.si-octi-comment::before{content:""}.si-octi-comments::before{content:""}.si-octi-tach::before{content:""}.si-octi-device-camera::before{content:""}.si-octi-device-camera-video::before{content:""}.si-octi-device-desktop::before{content:""}.si-octi-diff::before{content:""}.si-octi-file-binary::before{content:""}.si-octi-file-media::before{content:""}.si-octi-file-submodule::before{content:""}.si-octi-file-symlink-directory::before{content:""}.si-octi-file-symlink-file::before{content:""}.si-octi-fold::before{content:""}.si-octi-git-branch::before{content:""}.si-octi-git-commit::before{content:""}.si-octi-git-compare::before{content:""}.si-octi-git-merge::before{content:""}.si-octi-git-pull-request::before{content:""}.si-octi-graph::before{content:""}.si-octi-home::before{content:""}.si-octi-horizontal-rule::before{content:""}.si-octi-key::before{content:""}.si-octi-light-bulb::before{content:""}.si-octi-link-external::before{content:""}.si-octi-lock::before{content:""}.si-octi-markdown::before{content:""}.si-octi-microscope::before{content:""}.si-octi-mirror::before{content:""}.si-octi-move-down::before{content:""}.si-octi-move-left::before{content:""}.si-octi-move-right::before{content:""}.si-octi-move-up::before{content:""}.si-octi-mute::before{content:""}.si-octi-organization::before{content:""}.si-octi-package::before{content:""}.si-octi-paintcan::before{content:""}.si-octi-person::before{content:""}.si-octi-plug::before{content:""}.si-octi-podium::before{content:""}.si-octi-pulse::before{content:""}.si-octi-puzzle::before{content:""}.si-octi-repo::before{content:""}.si-octi-repo-clone::before{content:""}.si-octi-repo-force-push::before{content:""}.si-octi-repo-forked::before{content:""}.si-octi-repo-pull::before{content:""}.si-octi-repo-push::before{content:""}.si-octi-rocket::before{content:""}.si-octi-ruby::before{content:""}.si-octi-screen-full::before{content:""}.si-octi-screen-normal::before{content:""}.si-octi-sign-in::before{content:""}.si-octi-sign-out::before{content:""}.si-octi-split::before{content:""}.si-octi-squirrel::before{content:""}.si-octi-steps::before{content:""}.si-octi-tag::before{content:""}.si-octi-telescope::before{content:""}.si-octi-terminal::before{content:""}.si-octi-unfold::before{content:""}.si-octi-versions::before{content:""}.si-glass::before{content:""}.si-music::before{content:""}.si-search::before{content:""}.si-envelope-o::before{content:""}.si-heart::before{content:""}.si-star::before{content:""}.si-star-o::before{content:""}.si-user::before{content:""}.si-film::before{content:""}.si-th-large::before{content:""}.si-th::before{content:""}.si-th-list::before{content:""}.si-check::before{content:""}.si-close::before{content:""}.si-search-plus::before{content:""}.si-search-minus::before{content:""}.si-power-off::before{content:""}.si-signal::before{content:""}.si-cog::before{content:""}.si-trash-o::before{content:""}.si-home::before{content:""}.si-file-o::before{content:""}.si-clock-o::before{content:""}.si-road::before{content:""}.si-download::before{content:""}.si-arrow-circle-o-down::before{content:""}.si-arrow-circle-o-up::before{content:""}.si-inbox::before{content:""}.si-play-circle-o::before{content:""}.si-repeat::before{content:""}.si-refresh::before{content:""}.si-list-alt::before{content:""}.si-lock::before{content:""}.si-flag::before{content:""}.si-headphones::before{content:""}.si-volume-off::before{content:""}.si-volume-down::before{content:""}.si-volume-up::before{content:""}.si-qrcode::before{content:""}.si-barcode::before{content:""}.si-tag::before{content:""}.si-tags::before{content:""}.si-book::before{content:""}.si-bookmark::before{content:""}.si-print::before{content:""}.si-camera::before{content:""}.si-font::before{content:""}.si-bold::before{content:""}.si-italic::before{content:""}.si-text-height::before{content:""}.si-text-width::before{content:""}.si-align-left::before{content:""}.si-align-center::before{content:""}.si-align-right::before{content:""}.si-align-justify::before{content:""}.si-list::before{content:""}.si-dedent::before{content:""}.si-indent::before{content:""}.si-video-camera::before{content:""}.si-image::before{content:""}.si-pencil::before{content:""}.si-map-marker::before{content:""}.si-adjust::before{content:""}.si-tint::before{content:""}.si-edit::before{content:""}.si-share-square-o::before{content:""}.si-check-square-o::before{content:""}.si-arrows::before{content:""}.si-step-backward::before{content:""}.si-fast-backward::before{content:""}.si-backward::before{content:""}.si-play::before{content:""}.si-pause::before{content:""}.si-stop::before{content:""}.si-forward::before{content:""}.si-fast-forward::before{content:""}.si-step-forward::before{content:""}.si-eject::before{content:""}.si-chevron-left::before{content:""}.si-chevron-right::before{content:""}.si-plus-circle::before{content:""}.si-minus-circle::before{content:""}.si-times-circle::before{content:""}.si-check-circle::before{content:""}.si-question-circle::before{content:""}.si-info-circle::before{content:""}.si-crosshairs::before{content:""}.si-times-circle-o::before{content:""}.si-check-circle-o::before{content:""}.si-ban::before{content:""}.si-arrow-left::before{content:""}.si-arrow-right::before{content:""}.si-arrow-up::before{content:""}.si-arrow-down::before{content:""}.si-mail-forward::before{content:""}.si-expand::before{content:""}.si-compress::before{content:""}.si-plus::before{content:""}.si-minus::before{content:""}.si-asterisk::before{content:""}.si-exclamation-circle::before{content:""}.si-gift::before{content:""}.si-leaf::before{content:""}.si-fire::before{content:""}.si-eye::before{content:""}.si-eye-slash::before{content:""}.si-exclamation-triangle::before{content:""}.si-plane::before{content:""}.si-calendar::before{content:""}.si-random::before{content:""}.si-comment::before{content:""}.si-magnet::before{content:""}.si-chevron-up::before{content:""}.si-chevron-down::before{content:""}.si-retweet::before{content:""}.si-shopping-cart::before{content:""}.si-folder::before{content:""}.si-folder-open::before{content:""}.si-arrows-v::before{content:""}.si-arrows-h::before{content:""}.si-bar-chart::before{content:""}.si-twitter-square::before{content:""}.si-facebook-square::before{content:""}.si-camera-retro::before{content:""}.si-key::before{content:""}.si-cogs::before{content:""}.si-comments::before{content:""}.si-thumbs-o-up::before{content:""}.si-thumbs-o-down::before{content:""}.si-star-half::before{content:""}.si-heart-o::before{content:""}.si-sign-out::before{content:""}.si-linkedin-square::before{content:""}.si-thumb-tack::before{content:""}.si-external-link::before{content:""}.si-sign-in::before{content:""}.si-trophy::before{content:""}.si-github-square::before{content:""}.si-upload::before{content:""}.si-lemon-o::before{content:""}.si-phone::before{content:""}.si-square-o::before{content:""}.si-bookmark-o::before{content:""}.si-phone-square::before{content:""}.si-twitter::before{content:""}.si-facebook::before{content:""}.si-github::before{content:""}.si-unlock::before{content:""}.si-credit-card::before{content:""}.si-feed::before{content:""}.si-hdd-o::before{content:""}.si-bullhorn::before{content:""}.si-bell-o::before{content:""}.si-certificate::before{content:""}.si-hand-o-right::before{content:""}.si-hand-o-left::before{content:""}.si-hand-o-up::before{content:""}.si-hand-o-down::before{content:""}.si-arrow-circle-left::before{content:""}.si-arrow-circle-right::before{content:""}.si-arrow-circle-up::before{content:""}.si-arrow-circle-down::before{content:""}.si-globe::before{content:""}.si-wrench::before{content:""}.si-tasks::before{content:""}.si-filter::before{content:""}.si-briefcase::before{content:""}.si-arrows-alt::before{content:""}.si-group::before{content:""}.si-chain::before{content:""}.si-cloud::before{content:""}.si-flask::before{content:""}.si-cut::before{content:""}.si-copy::before{content:""}.si-paperclip::before{content:""}.si-floppy-o::before{content:""}.si-square::before{content:""}.si-bars::before{content:""}.si-list-ul::before{content:""}.si-list-ol::before{content:""}.si-strikethrough::before{content:""}.si-underline::before{content:""}.si-table::before{content:""}.si-magic::before{content:""}.si-truck::before{content:""}.si-pinterest::before{content:""}.si-pinterest-square::before{content:""}.si-google-plus-square::before{content:""}.si-google-plus::before{content:""}.si-money::before{content:""}.si-caret-down::before{content:""}.si-caret-up::before{content:""}.si-caret-left::before{content:""}.si-caret-right::before{content:""}.si-columns::before{content:""}.si-sort::before{content:""}.si-sort-desc::before{content:""}.si-sort-asc::before{content:""}.si-envelope::before{content:""}.si-linkedin::before{content:""}.si-rotate-left::before{content:""}.si-gavel::before{content:""}.si-dashboard::before{content:""}.si-comment-o::before{content:""}.si-comments-o::before{content:""}.si-bolt::before{content:""}.si-sitemap::before{content:""}.si-umbrella::before{content:""}.si-clipboard::before{content:""}.si-lightbulb-o::before{content:""}.si-exchange::before{content:""}.si-cloud-download::before{content:""}.si-cloud-upload::before{content:""}.si-user-md::before{content:""}.si-stethoscope::before{content:""}.si-suitcase::before{content:""}.si-bell::before{content:""}.si-coffee::before{content:""}.si-cutlery::before{content:""}.si-file-text-o::before{content:""}.si-building-o::before{content:""}.si-hospital-o::before{content:""}.si-ambulance::before{content:""}.si-medkit::before{content:""}.si-fighter-jet::before{content:""}.si-beer::before{content:""}.si-h-square::before{content:""}.si-plus-square::before{content:""}.si-angle-double-left::before{content:""}.si-angle-double-right::before{content:""}.si-angle-double-up::before{content:""}.si-angle-double-down::before{content:""}.si-angle-left::before{content:""}.si-angle-right::before{content:""}.si-angle-up::before{content:""}.si-angle-down::before{content:""}.si-desktop::before{content:""}.si-laptop::before{content:""}.si-tablet::before{content:""}.si-mobile::before{content:""}.si-circle-o::before{content:""}.si-quote-left::before{content:""}.si-quote-right::before{content:""}.si-spinner::before{content:""}.si-circle::before{content:""}.si-mail-reply::before{content:""}.si-github-alt::before{content:""}.si-folder-o::before{content:""}.si-folder-open-o::before{content:""}.si-smile-o::before{content:""}.si-frown-o::before{content:""}.si-meh-o::before{content:""}.si-gamepad::before{content:""}.si-keyboard-o::before{content:""}.si-flag-o::before{content:""}.si-flag-checkered::before{content:""}.si-terminal::before{content:""}.si-code::before{content:""}.si-mail-reply-all::before{content:""}.si-star-half-empty::before{content:""}.si-location-arrow::before{content:""}.si-crop::before{content:""}.si-code-fork::before{content:""}.si-chain-broken::before{content:""}.si-question::before{content:""}.si-info::before{content:""}.si-exclamation::before{content:""}.si-superscript::before{content:""}.si-subscript::before{content:""}.si-eraser::before{content:""}.si-puzzle-piece::before{content:""}.si-microphone::before{content:""}.si-microphone-slash::before{content:""}.si-shield::before{content:""}.si-calendar-o::before{content:""}.si-fire-extinguisher::before{content:""}.si-rocket::before{content:""}.si-maxcdn::before{content:""}.si-chevron-circle-left::before{content:""}.si-chevron-circle-right::before{content:""}.si-chevron-circle-up::before{content:""}.si-chevron-circle-down::before{content:""}.si-html5::before{content:""}.si-css3::before{content:""}.si-anchor::before{content:""}.si-unlock-alt::before{content:""}.si-bullseye::before{content:""}.si-ellipsis-h::before{content:""}.si-ellipsis-v::before{content:""}.si-rss-square::before{content:""}.si-play-circle::before{content:""}.si-ticket::before{content:""}.si-minus-square::before{content:""}.si-minus-square-o::before{content:""}.si-level-up::before{content:""}.si-level-down::before{content:""}.si-check-square::before{content:""}.si-pencil-square::before{content:""}.si-external-link-square::before{content:""}.si-share-square::before{content:""}.si-compass::before{content:""}.si-caret-square-o-down::before{content:""}.si-caret-square-o-up::before{content:""}.si-caret-square-o-right::before{content:""}.si-eur::before{content:""}.si-gbp::before{content:""}.si-dollar::before{content:""}.si-inr::before{content:""}.si-cny::before{content:""}.si-rouble::before{content:""}.si-krw::before{content:""}.si-bitcoin::before{content:""}.si-file::before{content:""}.si-file-text::before{content:""}.si-sort-alpha-asc::before{content:""}.si-sort-alpha-desc::before{content:""}.si-sort-amount-asc::before{content:""}.si-sort-amount-desc::before{content:""}.si-sort-numeric-asc::before{content:""}.si-sort-numeric-desc::before{content:""}.si-thumbs-up::before{content:""}.si-thumbs-down::before{content:""}.si-youtube-square::before{content:""}.si-youtube::before{content:""}.si-xing::before{content:""}.si-xing-square::before{content:""}.si-youtube-play::before{content:""}.si-dropbox::before{content:""}.si-stack-overflow::before{content:""}.si-instagram::before{content:""}.si-flickr::before{content:""}.si-adn::before{content:""}.si-bitbucket::before{content:""}.si-bitbucket-square::before{content:""}.si-tumblr::before{content:""}.si-tumblr-square::before{content:""}.si-long-arrow-down::before{content:""}.si-long-arrow-up::before{content:""}.si-long-arrow-left::before{content:""}.si-long-arrow-right::before{content:""}.si-apple::before{content:""}.si-windows::before{content:""}.si-android::before{content:""}.si-linux::before{content:""}.si-dribbble::before{content:""}.si-skype::before{content:""}.si-foursquare::before{content:""}.si-trello::before{content:""}.si-female::before{content:""}.si-male::before{content:""}.si-gittip::before{content:""}.si-sun-o::before{content:""}.si-moon-o::before{content:""}.si-archive::before{content:""}.si-bug::before{content:""}.si-vk::before{content:""}.si-weibo::before{content:""}.si-renren::before{content:""}.si-pagelines::before{content:""}.si-stack-exchange::before{content:""}.si-arrow-circle-o-right::before{content:""}.si-arrow-circle-o-left::before{content:""}.si-caret-square-o-left::before{content:""}.si-dot-circle-o::before{content:""}.si-wheelchair::before{content:""}.si-vimeo-square::before{content:""}.si-try::before{content:""}.si-plus-square-o::before{content:""}.si-space-shuttle::before{content:""}.si-slack::before{content:""}.si-envelope-square::before{content:""}.si-wordpress::before{content:""}.si-openid::before{content:""}.si-bank::before{content:""}.si-graduation-cap::before{content:""}.si-yahoo::before{content:""}.si-google::before{content:""}.si-reddit::before{content:""}.si-reddit-square::before{content:""}.si-stumbleupon-circle::before{content:""}.si-stumbleupon::before{content:""}.si-delicious::before{content:""}.si-digg::before{content:""}.si-pied-piper::before{content:""}.si-pied-piper-alt::before{content:""}.si-drupal::before{content:""}.si-joomla::before{content:""}.si-language::before{content:""}.si-fax::before{content:""}.si-building::before{content:""}.si-child::before{content:""}.si-paw::before{content:""}.si-spoon::before{content:""}.si-cube::before{content:""}.si-cubes::before{content:""}.si-behance::before{content:""}.si-behance-square::before{content:""}.si-steam::before{content:""}.si-steam-square::before{content:""}.si-recycle::before{content:""}.si-automobile::before{content:""}.si-cab::before{content:""}.si-tree::before{content:""}.si-spotify::before{content:""}.si-deviantart::before{content:""}.si-soundcloud::before{content:""}.si-database::before{content:""}.si-file-pdf-o::before{content:""}.si-file-word-o::before{content:""}.si-file-excel-o::before{content:""}.si-file-powerpoint-o::before{content:""}.si-file-image-o::before{content:""}.si-file-archive-o::before{content:""}.si-file-audio-o::before{content:""}.si-file-movie-o::before{content:""}.si-file-code-o::before{content:""}.si-vine::before{content:""}.si-codepen::before{content:""}.si-jsfiddle::before{content:""}.si-life-bouy::before{content:""}.si-circle-o-notch::before{content:""}.si-ra::before{content:""}.si-empire::before{content:""}.si-git-square::before{content:""}.si-git::before{content:""}.si-hacker-news::before{content:""}.si-tencent-weibo::before{content:""}.si-qq::before{content:""}.si-wechat::before{content:""}.si-paper-plane::before{content:""}.si-paper-plane-o::before{content:""}.si-history::before{content:""}.si-circle-thin::before{content:""}.si-header::before{content:""}.si-paragraph::before{content:""}.si-sliders::before{content:""}.si-share-alt::before{content:""}.si-share-alt-square::before{content:""}.si-bomb::before{content:""}.si-futbol-o::before{content:""}.si-tty::before{content:""}.si-binoculars::before{content:""}.si-plug::before{content:""}.si-slideshare::before{content:""}.si-twitch::before{content:""}.si-yelp::before{content:""}.si-newspaper-o::before{content:""}.si-wifi::before{content:""}.si-calculator::before{content:""}.si-paypal::before{content:""}.si-google-wallet::before{content:""}.si-cc-visa::before{content:""}.si-cc-mastercard::before{content:""}.si-cc-discover::before{content:""}.si-cc-amex::before{content:""}.si-cc-paypal::before{content:""}.si-cc-stripe::before{content:""}.si-bell-slash::before{content:""}.si-bell-slash-o::before{content:""}.si-trash::before{content:""}.si-copyright::before{content:""}.si-at::before{content:""}.si-eyedropper::before{content:""}.si-paint-brush::before{content:""}.si-birthday-cake::before{content:""}.si-area-chart::before{content:""}.si-pie-chart::before{content:""}.si-line-chart::before{content:""}.si-lastfm::before{content:""}.si-lastfm-square::before{content:""}.si-toggle-off::before{content:""}.si-toggle-on::before{content:""}.si-bicycle::before{content:""}.si-bus::before{content:""}.si-ioxhost::before{content:""}.si-angellist::before{content:""}.si-cc::before{content:""}.si-ils::before{content:""}.si-meanpath::before{content:""}.si-buysellads::before{content:""}.si-connectdevelop::before{content:""}.si-dashcube::before{content:""}.si-forumbee::before{content:""}.si-leanpub::before{content:""}.si-sellsy::before{content:""}.si-shirtsinbulk::before{content:""}.si-simplybuilt::before{content:""}.si-skyatlas::before{content:""}.si-cart-plus::before{content:""}.si-cart-arrow-down::before{content:""}.si-diamond::before{content:""}.si-ship::before{content:""}.si-user-secret::before{content:""}.si-motorcycle::before{content:""}.si-street-view::before{content:""}.si-heartbeat::before{content:""}.si-venus::before{content:""}.si-mars::before{content:""}.si-mercury::before{content:""}.si-intersex::before{content:""}.si-transgender-alt::before{content:""}.si-venus-double::before{content:""}.si-mars-double::before{content:""}.si-venus-mars::before{content:""}.si-mars-stroke::before{content:""}.si-mars-stroke-v::before{content:""}.si-mars-stroke-h::before{content:""}.si-neuter::before{content:""}.si-genderless::before{content:""}.si-facebook-official::before{content:""}.si-pinterest-p::before{content:""}.si-whatsapp::before{content:""}.si-server::before{content:""}.si-user-plus::before{content:""}.si-user-times::before{content:""}.si-bed::before{content:""}.si-viacoin::before{content:""}.si-train::before{content:""}.si-subway::before{content:""}.si-medium::before{content:""}.si-y-combinator::before{content:""}.si-optin-monster::before{content:""}.si-opencart::before{content:""}.si-expeditedssl::before{content:""}.si-battery-4::before{content:""}.si-battery-3::before{content:""}.si-battery-2::before{content:""}.si-battery-1::before{content:""}.si-battery-0::before{content:""}.si-mouse-pointer::before{content:""}.si-i-cursor::before{content:""}.si-object-group::before{content:""}.si-object-ungroup::before{content:""}.si-sticky-note::before{content:""}.si-sticky-note-o::before{content:""}.si-cc-jcb::before{content:""}.si-cc-diners-club::before{content:""}.si-clone::before{content:""}.si-balance-scale::before{content:""}.si-hourglass-o::before{content:""}.si-hourglass-1::before{content:""}.si-hourglass-2::before{content:""}.si-hourglass-3::before{content:""}.si-hourglass::before{content:""}.si-hand-grab-o::before{content:""}.si-hand-paper-o::before{content:""}.si-hand-scissors-o::before{content:""}.si-hand-lizard-o::before{content:""}.si-hand-spock-o::before{content:""}.si-hand-pointer-o::before{content:""}.si-hand-peace-o::before{content:""}.si-trademark::before{content:""}.si-registered::before{content:""}.si-creative-commons::before{content:""}.si-gg::before{content:""}.si-gg-circle::before{content:""}.si-tripadvisor::before{content:""}.si-odnoklassniki::before{content:""}.si-odnoklassniki-square::before{content:""}.si-get-pocket::before{content:""}.si-wikipedia-w::before{content:""}.si-safari::before{content:""}.si-chrome::before{content:""}.si-firefox::before{content:""}.si-opera::before{content:""}.si-internet-explorer::before{content:""}.si-television::before{content:""}.si-contao::before{content:""}.si-500px::before{content:""}.si-amazon::before{content:""}.si-calendar-plus-o::before{content:""}.si-calendar-minus-o::before{content:""}.si-calendar-times-o::before{content:""}.si-calendar-check-o::before{content:""}.si-industry::before{content:""}.si-map-pin::before{content:""}.si-map-signs::before{content:""}.si-map-o::before{content:""}.si-map::before{content:""}.si-commenting::before{content:""}.si-commenting-o::before{content:""}.si-houzz::before{content:""}.si-vimeo::before{content:""}.si-black-tie::before{content:""}.si-fonticons::before{content:""}.si-lg{font-size:1.33333333em;line-height:0.75em;vertical-align:-15%}.si-2x{font-size:2em}.si-3x{font-size:3em}.si-4x{font-size:4em}.si-5x{font-size:5em}.si-fw{text-align:center;width:1.28571429em}.si-border{border-radius:.1em;padding:.2em .25em .15em;border:solid 0.08em}.si-pull-left{float:left;margin-right:.3em}.si-pull-right{float:right;margin-left:.3em}.si-rotate-90{-webkit-transform:rotate(90deg);-moz-transform:rotate(90deg);-ms-transform:rotate(90deg);-o-transform:rotate(90deg);transform:rotate(90deg)}.si-rotate-180{-webkit-transform:rotate(180deg);-moz-transform:rotate(180deg);-ms-transform:rotate(180deg);-o-transform:rotate(180deg);transform:rotate(180deg)}.si-rotate-270{-webkit-transform:rotate(270deg);-moz-transform:rotate(270deg);-ms-transform:rotate(270deg);-o-transform:rotate(270deg);transform:rotate(270deg)}.si-flip-horizontal{-webkit-transform:scale(-1, 1);-moz-transform:scale(-1, 1);-ms-transform:scale(-1, 1);-o-transform:scale(-1, 1);transform:scale(-1, 1)}.si-flip-vertical{-webkit-transform:scale(1, -1);-moz-transform:scale(1, -1);-ms-transform:scale(1, -1);-o-transform:scale(1, -1);transform:scale(1, -1)}.si-inverse{-webkit-filter:invert(100%);filter:invert(100%)}.si-spin{-webkit-animation:si-animation-spin 2s infinite linear;-moz-animation:si-animation-spin 2s infinite linear;animation:si-animation-spin 2s infinite linear}.si-pulse{-webkit-animation:si-animation-spin 1s infinite steps(8);-moz-animation:si-animation-spin 1s infinite steps(8);animation:si-animation-spin 1s infinite steps(8)}.si-ul{padding-left:0;list-style-type:none;margin-left:2.14285714em}.si-ul>li{position:relative}.si-ul>li .si-li{text-align:center;position:absolute;left:-2.14285714em;width:2.14285714em;top:0.14285714em}.si-ul>li .si-li .si-lg{left:-1.85714286em}.si-stack{width:2em;height:2em;line-height:2em;vertical-align:middle;position:relative;display:inline-block}.si-stack .si-stack-1x,.si-stack .si-stack-2x{left:0;width:100%;text-align:center;position:absolute}.si-stack .si-stack-1x{line-height:inherit}.si-stack .si-stack-2x{font-size:2em}@-webkit-keyframes si-animation-spin{0%{-webkit-transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg)}}@-moz-keyframes si-animation-spin{0%{-moz-transform:rotate(0deg)}100%{-moz-transform:rotate(359deg)}}@keyframes si-animation-spin{0%{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);-ms-transform:rotate(0deg);-o-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);-moz-transform:rotate(359deg);-ms-transform:rotate(359deg);-o-transform:rotate(359deg);transform:rotate(359deg)}}.plugin-menu-page-animation-spin{-webkit-animation-duration:0.75s;-moz-animation-duration:0.75s;animation-duration:0.75s;-webkit-animation-fill-mode:both;-moz-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:linear;-moz-animation-timing-function:linear;animation-timing-function:linear;-webkit-animation-iteration-count:infinite;-moz-animation-iteration-count:infinite;animation-iteration-count:infinite;-webkit-animation-name:plugin-menu-page-animation-spin;-moz-animation-name:plugin-menu-page-animation-spin;animation-name:plugin-menu-page-animation-spin}@-webkit-keyframes plugin-menu-page-animation-spin{0%{-webkit-transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg)}}@-moz-keyframes plugin-menu-page-animation-spin{0%{-moz-transform:rotate(0deg)}100%{-moz-transform:rotate(360deg)}}@keyframes plugin-menu-page-animation-spin{0%{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);-ms-transform:rotate(0deg);-o-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);-ms-transform:rotate(360deg);-o-transform:rotate(360deg);transform:rotate(360deg)}}html{overflow-y:scroll}#wpwrap{position:relative}#wpwrap::after{top:0;right:0;bottom:0;left:0;z-index:-1;position:absolute;content:'';opacity:0.25;background:url("../images/bg.png")}#wpwrap .updated,#wpwrap .error{margin:1.25em 1.25em 1.25em 0.25em}.plugin-menu-page{min-width:800px;margin:1.25em 1.25em 1.25em 0.25em}.plugin-menu-page,.plugin-menu-page p{font-size:14px}.plugin-menu-page a{color:#033A63}.plugin-menu-page a:hover,.plugin-menu-page a:active{color:#467629}.plugin-menu-page p:first-child,.plugin-menu-page pre:first-child{margin-top:0}.plugin-menu-page p:last-child,.plugin-menu-page pre:last-child{margin-bottom:0}.plugin-menu-page code{border-radius:3px;padding:0.1em 0.25em;background:rgba(178,178,178,0.25);font-family:'Menlo', 'Monaco', 'Consolas', 'Courier New', monospace}.plugin-menu-page pre.code{padding:0;background:none}.plugin-menu-page pre.code>code{font-size:90%;overflow-x:auto;max-width:100%;border-radius:4px;padding:1em;display:block;color:#eee;background:#222;box-shadow:0 0 5px 1px #000 inset}.plugin-menu-page img{border:0}.plugin-menu-page img.screenshot{float:right;border-radius:4px;padding:0.5em;margin:0 0 2em 2em;background:#fff;border:1px solid #afafaf;box-shadow:0 0 5px 0 rgba(0,0,0,0.2) inset}.plugin-menu-page hr{border:0;padding:0;height:1px;margin:1em 0;background:linear-gradient(to left, transparent, rgba(0,0,0,0.75), transparent)}.plugin-menu-page label{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.plugin-menu-page label.switch-primary{font-size:130%;margin:0;padding:0.5em;border-radius:4px;display:inline;color:#000;background:#f1e982;border:1px solid rgba(0,0,0,0.07);box-shadow:-1px -1px 0 0 rgba(0,0,0,0.25) inset,1px 1px 0 0 #fff inset}.plugin-menu-page select,.plugin-menu-page textarea,.plugin-menu-page select:focus,.plugin-menu-page textarea:focus,.plugin-menu-page input:not([type='radio']):not([type='checkbox']),.plugin-menu-page input:not([type='radio']):not([type='checkbox']):focus{width:100%;line-height:1.3em;margin:0;padding:0.25em 0.5em;border-radius:4px;box-sizing:border-box;color:#333;background:#e8e8e8;border:1px solid #848484;box-shadow:0 0 2px 0 rgba(132,132,132,0.5) inset}.plugin-menu-page select,.plugin-menu-page select:focus{box-shadow:0 1px 0 0 #fff inset,0 -2px 3px 0 rgba(132,132,132,0.25) inset}.plugin-menu-page select,.plugin-menu-page select:focus,.plugin-menu-page input:not([type='radio']):not([type='checkbox']),.plugin-menu-page input:not([type='radio']):not([type='checkbox']):focus{height:2em}.plugin-menu-page select:focus,.plugin-menu-page textarea:focus,.plugin-menu-page input:not([type='radio']):not([type='checkbox']):focus{color:#000;background:#e2e2e2}.plugin-menu-page input[disabled],.plugin-menu-page select[disabled],.plugin-menu-page textarea[disabled]{opacity:0.5}.plugin-menu-page input::-webkit-input-placeholder,.plugin-menu-page textarea::-webkit-input-placeholder{font-style:italic;color:rgba(0,0,0,0.2)}.plugin-menu-page input::-moz-placeholder,.plugin-menu-page textarea::-moz-placeholder{font-style:italic;color:rgba(0,0,0,0.2)}.plugin-menu-page input:-moz-placeholder,.plugin-menu-page textarea:-moz-placeholder{font-style:italic;color:rgba(0,0,0,0.2)}.plugin-menu-page input:-ms-input-placeholder,.plugin-menu-page textarea:-ms-input-placeholder{font-style:italic;color:rgba(0,0,0,0.2)}.plugin-menu-page table{margin:1em 0}.plugin-menu-page button{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;font-size:150%;font-weight:bold;line-height:1em;outline:none;cursor:pointer;border-radius:4px;margin:0;padding:0.25em 0.5em;box-sizing:border-box;color:#fff;background:#033A63;border:1px solid rgba(0,0,0,0.5);box-shadow:0 1px 1px 0 rgba(0,0,0,0.25),-1px -1px 0 0 rgba(0,0,0,0.2) inset,1px 1px 0 0 rgba(255,255,255,0.1) inset}.plugin-menu-page button:hover{background:#467629}.plugin-menu-page button[type='submit']{background:#467629}.plugin-menu-page button[type='submit']:hover{background:#033A63}.plugin-menu-page button:active{-webkit-transform:scale(0.98, 0.98);-moz-transform:scale(0.98, 0.98);-ms-transform:scale(0.98, 0.98);-o-transform:scale(0.98, 0.98);transform:scale(0.98, 0.98)}.plugin-menu-page .info,.plugin-menu-page .notice,.plugin-menu-page .warning,.plugin-menu-page .error{border-radius:4px;padding:0.5em;margin:1em 0}.plugin-menu-page .info{background:#cadfed;border:1px solid #216095}.plugin-menu-page .notice{background:#fffde8;border:1px solid #e6db55}.plugin-menu-page .warning{background:#ffefd3;border:1px solid #e6db55}.plugin-menu-page .error{background:pink;border:1px solid #711e1e}.plugin-menu-page .monospace{font-family:'Menlo', 'Monaco', 'Consolas', 'Courier New', monospace}.plugin-menu-page textarea.monospace{white-space:pre}.plugin-menu-page .clearfix::before,.plugin-menu-page .clearfix::after{display:table;content:' '}.plugin-menu-page .clearfix::after{clear:both}.plugin-menu-page-heading .plugin-menu-page-restore-defaults,.plugin-menu-page-heading .plugin-menu-page-panel-togglers{float:right;margin:0 1em 0 0}.plugin-menu-page-heading .plugin-menu-page-panel-togglers button{background:#033A63 !important}.plugin-menu-page-heading .plugin-menu-page-upsells{float:right;clear:right;text-align:right;max-width:350px;margin:1em 0 0}.plugin-menu-page-heading .plugin-menu-page-upsells a{text-decoration:none;line-height:1.5em;margin:0 0.5em;display:inline-block}.plugin-menu-page-heading .plugin-menu-page-support-links,.plugin-menu-page-heading .plugin-menu-page-mailing-list-links{float:right;clear:right;text-align:right;max-width:400px;margin:.5em 0 0}.plugin-menu-page-heading .plugin-menu-page-support-links a,.plugin-menu-page-heading .plugin-menu-page-mailing-list-links a{text-decoration:none;margin:0 0.5em;display:inline-block}.plugin-menu-page-heading .plugin-menu-page-version{float:right;clear:right;min-width:350px;margin:0.5em 0 0 0;text-align:right}.plugin-menu-page-body{position:relative}.plugin-menu-page-section-heading{margin:1em 0}.plugin-menu-page-section-heading>small{font-size:65%;font-style:italic;margin:0;display:block;opacity:0.5}.plugin-menu-page-panel{margin:1em 0}.plugin-menu-page-panel:first-child{margin-top:0}.plugin-menu-page-panel .plugin-menu-page-panel-heading{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;text-decoration:none;padding:10px;font-size:150%;line-height:1.125em;font-weight:bold;border-radius:4px;display:block;cursor:pointer;background:#033A63;background:linear-gradient(to right, #033A63, #20669A);color:#eee !important;box-shadow:0 2px 2px 0 rgba(0,0,0,0.25)}.plugin-menu-page-panel .plugin-menu-page-panel-heading::after{font:normal normal normal 14px/1 sharkicons;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;font-smoothing:antialiased;display:inline-block;font-size:inherit;text-decoration:inherit;text-transform:none;content:""}.plugin-menu-page-panel .plugin-menu-page-panel-heading:hover,.plugin-menu-page-panel .plugin-menu-page-panel-heading.open{color:#fff !important}.plugin-menu-page-panel .plugin-menu-page-panel-heading::after{font-size:80%;float:right;margin:0 0 0 5px}.plugin-menu-page-panel .plugin-menu-page-panel-heading.open::after{content:""}.plugin-menu-page-panel-heading.pro-preview-feature{background:#216095}.pro-preview-feature::after{font-variant:small-caps !important;font-family:sans-serif !important;content:'pro version only' !important;margin-left:15px;background:#216095;color:#FFFFFF;padding:0 5px 2px 5px;font-weight:normal}.plugin-menu-page-panel-heading.pro-preview-additional-features{background:#216095}.pro-preview-additional-features::after{font-variant:small-caps !important;font-family:sans-serif !important;content:'additional pro features' !important;margin-left:15px;background:#216095;color:#FFFFFF;padding:0 5px 2px 5px;font-weight:normal}.plugin-menu-page-panel .plugin-menu-page-panel-heading>.si{text-align:center;width:1.28571429em;margin-right:.25em}.plugin-menu-page-panel .plugin-menu-page-panel-body{width:99%;margin:0 auto;display:none;padding:1.2em;border-bottom-left-radius:4px;border-bottom-right-radius:4px;box-sizing:border-box;color:#222;border:1px solid #848484;background:#fff;box-shadow:0 1px 1px 0 rgba(0,0,0,0.25),0 3px 1px -1px rgba(0,0,0,0.25) inset}.plugin-menu-page-panel .plugin-menu-page-panel-body.open{display:block}.plugin-menu-page-panel .plugin-menu-page-panel-body p{font-size:90%;color:#666}.plugin-menu-page-panel .plugin-menu-page-panel-body p.notice,.plugin-menu-page-panel .plugin-menu-page-panel-body p.info,.plugin-menu-page-panel .plugin-menu-page-panel-body p.warning,.plugin-menu-page-panel .plugin-menu-page-panel-body p.error{color:#000}.plugin-menu-page-panel .plugin-menu-page-panel-body h3{margin:0 0 0.5em}.plugin-menu-page-panel .plugin-menu-page-panel-body h3:first-child{margin-top:0}.plugin-menu-page-panel .plugin-menu-page-panel-body h3+p{margin-top:0}.plugin-menu-page-panel .plugin-menu-page-panel-body a.dotted{text-decoration:none;border-bottom:1px dotted}.plugin-menu-page-panel .plugin-menu-page-panel-body.pro-preview,.plugin-menu-page-panel .plugin-menu-page-panel-body .pro-preview{opacity:0.5}.plugin-menu-page-save{margin-top:2em}.plugin-menu-page-save button{line-height:1.3em;width:100%}.plugin-menu-page-save-and-update{margin-top:2em}.plugin-menu-page-save-and-update button{line-height:1.3em;display:inline;width:45%;margin-left:1.5em}
|
2 |
|
1 |
+
@font-face{font-family:sharkicons;src:url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.eot?v160221");src:url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.eot?#iefix&v160221") format("embedded-opentype"),url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.ttf?v160221") format("truetype"),url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.woff?v160221") format("woff"),url("../../vendor/websharks/sharkicons/src/fonts/sharkicons.svg?v160221#sharkicons") format("svg");font-weight:normal;font-style:normal}.si::before{font:normal normal normal 14px/1 sharkicons;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;font-smoothing:antialiased;display:inline-block;font-size:inherit;text-decoration:inherit;text-transform:none}.si-broom::before{content:""}.si-comment-mail-one::before{content:""}.si-comment-mail::before{content:""}.si-s2member::before{content:""}.si-websharks::before{content:""}.si-wp-kb-articles::before{content:""}.si-zencache-logo::before{content:""}.si-zencache::before{content:""}.si-wp-sharks::before{content:""}.si-wp-sharks-fin::before{content:""}.si-comet-cache::before{content:""}.si-comet-cache-logo::before{content:""}.si-comet-cache-comet::before{content:""}.si-feat-watch::before{content:""}.si-feat-server::before{content:""}.si-feat-layers::before{content:""}.si-feat-box::before{content:""}.si-feat-ellipsis::before{content:""}.si-typi-group::before{content:""}.si-enty-bookmark::before{content:""}.si-enty-bookmarks::before{content:""}.si-enty-open-book::before{content:""}.si-enty-archive::before{content:""}.si-enty-area-graph::before{content:""}.si-enty-bucket::before{content:""}.si-enty-colors::before{content:""}.si-enty-copy::before{content:""}.si-enty-drive::before{content:""}.si-enty-feather::before{content:""}.si-enty-gauge::before{content:""}.si-enty-hand::before{content:""}.si-enty-lab-flask::before{content:""}.si-enty-mask::before{content:""}.si-enty-medal::before{content:""}.si-enty-exclamation::before{content:""}.si-enty-palette::before{content:""}.si-enty-ruler::before{content:""}.si-enty-shop::before{content:""}.si-enty-basket::before{content:""}.si-enty-cart::before{content:""}.si-enty-traffic-cone::before{content:""}.si-enty-tree::before{content:""}.si-enty-trophy::before{content:""}.si-enty-v-card::before{content:""}.si-enty-google-hangouts::before{content:""}.si-eleg-line-graph::before{content:""}.si-eleg-male::before{content:""}.si-eleg-female::before{content:""}.si-eleg-atom::before{content:""}.si-broc-cart::before{content:""}.si-broc-crap::before{content:""}.si-broc-atom::before{content:""}.si-icom-headphones::before{content:""}.si-icom-barcode::before{content:""}.si-icom-user::before{content:""}.si-icom-users::before{content:""}.si-icom-user-plus::before{content:""}.si-icom-user-minus::before{content:""}.si-icom-user-check::before{content:""}.si-icom-user-tie::before{content:""}.si-icom-key::before{content:""}.si-icom-key2::before{content:""}.si-icom-happy::before{content:""}.si-icom-happy2::before{content:""}.si-icom-smile::before{content:""}.si-icom-smile2::before{content:""}.si-icom-tongue::before{content:""}.si-icom-tongue2::before{content:""}.si-icom-sad::before{content:""}.si-icom-sad2::before{content:""}.si-icom-wink::before{content:""}.si-icom-wink2::before{content:""}.si-icom-grin::before{content:""}.si-icom-grin2::before{content:""}.si-icom-cool::before{content:""}.si-icom-cool2::before{content:""}.si-icom-angry::before{content:""}.si-icom-angry2::before{content:""}.si-icom-evil::before{content:""}.si-icom-evil2::before{content:""}.si-icom-shocked::before{content:""}.si-icom-shocked2::before{content:""}.si-icom-baffled::before{content:""}.si-icom-baffled2::before{content:""}.si-icom-confused::before{content:""}.si-icom-confused2::before{content:""}.si-icom-neutral::before{content:""}.si-icom-neutral2::before{content:""}.si-icom-hipster::before{content:""}.si-icom-hipster2::before{content:""}.si-icom-wondering::before{content:""}.si-icom-wondering2::before{content:""}.si-icom-sleepy::before{content:""}.si-icom-sleepy2::before{content:""}.si-icom-frustrated::before{content:""}.si-icom-frustrated2::before{content:""}.si-icom-crying::before{content:""}.si-icom-crying2::before{content:""}.si-icom-spell-check::before{content:""}.si-icom-command-key::before{content:""}.si-icom-shift-key::before{content:""}.si-icom-control-key::before{content:""}.si-icom-option-key::before{content:""}.si-icom-wordpress::before{content:""}.si-icom-wordpress-square::before{content:""}.si-icom-yahoo::before{content:""}.si-icom-linux::before{content:""}.si-icom-finder::before{content:""}.si-icom-android::before{content:""}.si-icom-reddit::before{content:""}.si-icom-paypal::before{content:""}.si-icom-git::before{content:""}.si-octi-alignment-align::before{content:""}.si-octi-alignment-aligned-to::before{content:""}.si-octi-alignment-unalign::before{content:""}.si-octi-bookmark::before{content:""}.si-octi-broadcast::before{content:""}.si-octi-browser::before{content:""}.si-octi-checklist::before{content:""}.si-octi-circuit-board::before{content:""}.si-octi-clippy::before{content:""}.si-octi-cloud-download::before{content:""}.si-octi-cloud-upload::before{content:""}.si-octi-comment::before{content:""}.si-octi-comments::before{content:""}.si-octi-tach::before{content:""}.si-octi-device-camera::before{content:""}.si-octi-device-camera-video::before{content:""}.si-octi-device-desktop::before{content:""}.si-octi-diff::before{content:""}.si-octi-file-binary::before{content:""}.si-octi-file-media::before{content:""}.si-octi-file-submodule::before{content:""}.si-octi-file-symlink-directory::before{content:""}.si-octi-file-symlink-file::before{content:""}.si-octi-fold::before{content:""}.si-octi-git-branch::before{content:""}.si-octi-git-commit::before{content:""}.si-octi-git-compare::before{content:""}.si-octi-git-merge::before{content:""}.si-octi-git-pull-request::before{content:""}.si-octi-graph::before{content:""}.si-octi-home::before{content:""}.si-octi-horizontal-rule::before{content:""}.si-octi-key::before{content:""}.si-octi-light-bulb::before{content:""}.si-octi-link-external::before{content:""}.si-octi-lock::before{content:""}.si-octi-markdown::before{content:""}.si-octi-microscope::before{content:""}.si-octi-mirror::before{content:""}.si-octi-move-down::before{content:""}.si-octi-move-left::before{content:""}.si-octi-move-right::before{content:""}.si-octi-move-up::before{content:""}.si-octi-mute::before{content:""}.si-octi-organization::before{content:""}.si-octi-package::before{content:""}.si-octi-paintcan::before{content:""}.si-octi-person::before{content:""}.si-octi-plug::before{content:""}.si-octi-podium::before{content:""}.si-octi-pulse::before{content:""}.si-octi-puzzle::before{content:""}.si-octi-repo::before{content:""}.si-octi-repo-clone::before{content:""}.si-octi-repo-force-push::before{content:""}.si-octi-repo-forked::before{content:""}.si-octi-repo-pull::before{content:""}.si-octi-repo-push::before{content:""}.si-octi-rocket::before{content:""}.si-octi-ruby::before{content:""}.si-octi-screen-full::before{content:""}.si-octi-screen-normal::before{content:""}.si-octi-sign-in::before{content:""}.si-octi-sign-out::before{content:""}.si-octi-split::before{content:""}.si-octi-squirrel::before{content:""}.si-octi-steps::before{content:""}.si-octi-tag::before{content:""}.si-octi-telescope::before{content:""}.si-octi-terminal::before{content:""}.si-octi-unfold::before{content:""}.si-octi-versions::before{content:""}.si-glass::before{content:""}.si-music::before{content:""}.si-search::before{content:""}.si-envelope-o::before{content:""}.si-heart::before{content:""}.si-star::before{content:""}.si-star-o::before{content:""}.si-user::before{content:""}.si-film::before{content:""}.si-th-large::before{content:""}.si-th::before{content:""}.si-th-list::before{content:""}.si-check::before{content:""}.si-close::before{content:""}.si-search-plus::before{content:""}.si-search-minus::before{content:""}.si-power-off::before{content:""}.si-signal::before{content:""}.si-cog::before{content:""}.si-trash-o::before{content:""}.si-home::before{content:""}.si-file-o::before{content:""}.si-clock-o::before{content:""}.si-road::before{content:""}.si-download::before{content:""}.si-arrow-circle-o-down::before{content:""}.si-arrow-circle-o-up::before{content:""}.si-inbox::before{content:""}.si-play-circle-o::before{content:""}.si-repeat::before{content:""}.si-refresh::before{content:""}.si-list-alt::before{content:""}.si-lock::before{content:""}.si-flag::before{content:""}.si-headphones::before{content:""}.si-volume-off::before{content:""}.si-volume-down::before{content:""}.si-volume-up::before{content:""}.si-qrcode::before{content:""}.si-barcode::before{content:""}.si-tag::before{content:""}.si-tags::before{content:""}.si-book::before{content:""}.si-bookmark::before{content:""}.si-print::before{content:""}.si-camera::before{content:""}.si-font::before{content:""}.si-bold::before{content:""}.si-italic::before{content:""}.si-text-height::before{content:""}.si-text-width::before{content:""}.si-align-left::before{content:""}.si-align-center::before{content:""}.si-align-right::before{content:""}.si-align-justify::before{content:""}.si-list::before{content:""}.si-dedent::before{content:""}.si-indent::before{content:""}.si-video-camera::before{content:""}.si-image::before{content:""}.si-pencil::before{content:""}.si-map-marker::before{content:""}.si-adjust::before{content:""}.si-tint::before{content:""}.si-edit::before{content:""}.si-share-square-o::before{content:""}.si-check-square-o::before{content:""}.si-arrows::before{content:""}.si-step-backward::before{content:""}.si-fast-backward::before{content:""}.si-backward::before{content:""}.si-play::before{content:""}.si-pause::before{content:""}.si-stop::before{content:""}.si-forward::before{content:""}.si-fast-forward::before{content:""}.si-step-forward::before{content:""}.si-eject::before{content:""}.si-chevron-left::before{content:""}.si-chevron-right::before{content:""}.si-plus-circle::before{content:""}.si-minus-circle::before{content:""}.si-times-circle::before{content:""}.si-check-circle::before{content:""}.si-question-circle::before{content:""}.si-info-circle::before{content:""}.si-crosshairs::before{content:""}.si-times-circle-o::before{content:""}.si-check-circle-o::before{content:""}.si-ban::before{content:""}.si-arrow-left::before{content:""}.si-arrow-right::before{content:""}.si-arrow-up::before{content:""}.si-arrow-down::before{content:""}.si-mail-forward::before{content:""}.si-expand::before{content:""}.si-compress::before{content:""}.si-plus::before{content:""}.si-minus::before{content:""}.si-asterisk::before{content:""}.si-exclamation-circle::before{content:""}.si-gift::before{content:""}.si-leaf::before{content:""}.si-fire::before{content:""}.si-eye::before{content:""}.si-eye-slash::before{content:""}.si-exclamation-triangle::before{content:""}.si-plane::before{content:""}.si-calendar::before{content:""}.si-random::before{content:""}.si-comment::before{content:""}.si-magnet::before{content:""}.si-chevron-up::before{content:""}.si-chevron-down::before{content:""}.si-retweet::before{content:""}.si-shopping-cart::before{content:""}.si-folder::before{content:""}.si-folder-open::before{content:""}.si-arrows-v::before{content:""}.si-arrows-h::before{content:""}.si-bar-chart::before{content:""}.si-twitter-square::before{content:""}.si-facebook-square::before{content:""}.si-camera-retro::before{content:""}.si-key::before{content:""}.si-cogs::before{content:""}.si-comments::before{content:""}.si-thumbs-o-up::before{content:""}.si-thumbs-o-down::before{content:""}.si-star-half::before{content:""}.si-heart-o::before{content:""}.si-sign-out::before{content:""}.si-linkedin-square::before{content:""}.si-thumb-tack::before{content:""}.si-external-link::before{content:""}.si-sign-in::before{content:""}.si-trophy::before{content:""}.si-github-square::before{content:""}.si-upload::before{content:""}.si-lemon-o::before{content:""}.si-phone::before{content:""}.si-square-o::before{content:""}.si-bookmark-o::before{content:""}.si-phone-square::before{content:""}.si-twitter::before{content:""}.si-facebook::before{content:""}.si-github::before{content:""}.si-unlock::before{content:""}.si-credit-card::before{content:""}.si-feed::before{content:""}.si-hdd-o::before{content:""}.si-bullhorn::before{content:""}.si-bell-o::before{content:""}.si-certificate::before{content:""}.si-hand-o-right::before{content:""}.si-hand-o-left::before{content:""}.si-hand-o-up::before{content:""}.si-hand-o-down::before{content:""}.si-arrow-circle-left::before{content:""}.si-arrow-circle-right::before{content:""}.si-arrow-circle-up::before{content:""}.si-arrow-circle-down::before{content:""}.si-globe::before{content:""}.si-wrench::before{content:""}.si-tasks::before{content:""}.si-filter::before{content:""}.si-briefcase::before{content:""}.si-arrows-alt::before{content:""}.si-group::before{content:""}.si-chain::before{content:""}.si-cloud::before{content:""}.si-flask::before{content:""}.si-cut::before{content:""}.si-copy::before{content:""}.si-paperclip::before{content:""}.si-floppy-o::before{content:""}.si-square::before{content:""}.si-bars::before{content:""}.si-list-ul::before{content:""}.si-list-ol::before{content:""}.si-strikethrough::before{content:""}.si-underline::before{content:""}.si-table::before{content:""}.si-magic::before{content:""}.si-truck::before{content:""}.si-pinterest::before{content:""}.si-pinterest-square::before{content:""}.si-google-plus-square::before{content:""}.si-google-plus::before{content:""}.si-money::before{content:""}.si-caret-down::before{content:""}.si-caret-up::before{content:""}.si-caret-left::before{content:""}.si-caret-right::before{content:""}.si-columns::before{content:""}.si-sort::before{content:""}.si-sort-desc::before{content:""}.si-sort-asc::before{content:""}.si-envelope::before{content:""}.si-linkedin::before{content:""}.si-rotate-left::before{content:""}.si-gavel::before{content:""}.si-dashboard::before{content:""}.si-comment-o::before{content:""}.si-comments-o::before{content:""}.si-bolt::before{content:""}.si-sitemap::before{content:""}.si-umbrella::before{content:""}.si-clipboard::before{content:""}.si-lightbulb-o::before{content:""}.si-exchange::before{content:""}.si-cloud-download::before{content:""}.si-cloud-upload::before{content:""}.si-user-md::before{content:""}.si-stethoscope::before{content:""}.si-suitcase::before{content:""}.si-bell::before{content:""}.si-coffee::before{content:""}.si-cutlery::before{content:""}.si-file-text-o::before{content:""}.si-building-o::before{content:""}.si-hospital-o::before{content:""}.si-ambulance::before{content:""}.si-medkit::before{content:""}.si-fighter-jet::before{content:""}.si-beer::before{content:""}.si-h-square::before{content:""}.si-plus-square::before{content:""}.si-angle-double-left::before{content:""}.si-angle-double-right::before{content:""}.si-angle-double-up::before{content:""}.si-angle-double-down::before{content:""}.si-angle-left::before{content:""}.si-angle-right::before{content:""}.si-angle-up::before{content:""}.si-angle-down::before{content:""}.si-desktop::before{content:""}.si-laptop::before{content:""}.si-tablet::before{content:""}.si-mobile::before{content:""}.si-circle-o::before{content:""}.si-quote-left::before{content:""}.si-quote-right::before{content:""}.si-spinner::before{content:""}.si-circle::before{content:""}.si-mail-reply::before{content:""}.si-github-alt::before{content:""}.si-folder-o::before{content:""}.si-folder-open-o::before{content:""}.si-smile-o::before{content:""}.si-frown-o::before{content:""}.si-meh-o::before{content:""}.si-gamepad::before{content:""}.si-keyboard-o::before{content:""}.si-flag-o::before{content:""}.si-flag-checkered::before{content:""}.si-terminal::before{content:""}.si-code::before{content:""}.si-mail-reply-all::before{content:""}.si-star-half-empty::before{content:""}.si-location-arrow::before{content:""}.si-crop::before{content:""}.si-code-fork::before{content:""}.si-chain-broken::before{content:""}.si-question::before{content:""}.si-info::before{content:""}.si-exclamation::before{content:""}.si-superscript::before{content:""}.si-subscript::before{content:""}.si-eraser::before{content:""}.si-puzzle-piece::before{content:""}.si-microphone::before{content:""}.si-microphone-slash::before{content:""}.si-shield::before{content:""}.si-calendar-o::before{content:""}.si-fire-extinguisher::before{content:""}.si-rocket::before{content:""}.si-maxcdn::before{content:""}.si-chevron-circle-left::before{content:""}.si-chevron-circle-right::before{content:""}.si-chevron-circle-up::before{content:""}.si-chevron-circle-down::before{content:""}.si-html5::before{content:""}.si-css3::before{content:""}.si-anchor::before{content:""}.si-unlock-alt::before{content:""}.si-bullseye::before{content:""}.si-ellipsis-h::before{content:""}.si-ellipsis-v::before{content:""}.si-rss-square::before{content:""}.si-play-circle::before{content:""}.si-ticket::before{content:""}.si-minus-square::before{content:""}.si-minus-square-o::before{content:""}.si-level-up::before{content:""}.si-level-down::before{content:""}.si-check-square::before{content:""}.si-pencil-square::before{content:""}.si-external-link-square::before{content:""}.si-share-square::before{content:""}.si-compass::before{content:""}.si-caret-square-o-down::before{content:""}.si-caret-square-o-up::before{content:""}.si-caret-square-o-right::before{content:""}.si-eur::before{content:""}.si-gbp::before{content:""}.si-dollar::before{content:""}.si-inr::before{content:""}.si-cny::before{content:""}.si-rouble::before{content:""}.si-krw::before{content:""}.si-bitcoin::before{content:""}.si-file::before{content:""}.si-file-text::before{content:""}.si-sort-alpha-asc::before{content:""}.si-sort-alpha-desc::before{content:""}.si-sort-amount-asc::before{content:""}.si-sort-amount-desc::before{content:""}.si-sort-numeric-asc::before{content:""}.si-sort-numeric-desc::before{content:""}.si-thumbs-up::before{content:""}.si-thumbs-down::before{content:""}.si-youtube-square::before{content:""}.si-youtube::before{content:""}.si-xing::before{content:""}.si-xing-square::before{content:""}.si-youtube-play::before{content:""}.si-dropbox::before{content:""}.si-stack-overflow::before{content:""}.si-instagram::before{content:""}.si-flickr::before{content:""}.si-adn::before{content:""}.si-bitbucket::before{content:""}.si-bitbucket-square::before{content:""}.si-tumblr::before{content:""}.si-tumblr-square::before{content:""}.si-long-arrow-down::before{content:""}.si-long-arrow-up::before{content:""}.si-long-arrow-left::before{content:""}.si-long-arrow-right::before{content:""}.si-apple::before{content:""}.si-windows::before{content:""}.si-android::before{content:""}.si-linux::before{content:""}.si-dribbble::before{content:""}.si-skype::before{content:""}.si-foursquare::before{content:""}.si-trello::before{content:""}.si-female::before{content:""}.si-male::before{content:""}.si-gittip::before{content:""}.si-sun-o::before{content:""}.si-moon-o::before{content:""}.si-archive::before{content:""}.si-bug::before{content:""}.si-vk::before{content:""}.si-weibo::before{content:""}.si-renren::before{content:""}.si-pagelines::before{content:""}.si-stack-exchange::before{content:""}.si-arrow-circle-o-right::before{content:""}.si-arrow-circle-o-left::before{content:""}.si-caret-square-o-left::before{content:""}.si-dot-circle-o::before{content:""}.si-wheelchair::before{content:""}.si-vimeo-square::before{content:""}.si-try::before{content:""}.si-plus-square-o::before{content:""}.si-space-shuttle::before{content:""}.si-slack::before{content:""}.si-envelope-square::before{content:""}.si-wordpress::before{content:""}.si-openid::before{content:""}.si-bank::before{content:""}.si-graduation-cap::before{content:""}.si-yahoo::before{content:""}.si-google::before{content:""}.si-reddit::before{content:""}.si-reddit-square::before{content:""}.si-stumbleupon-circle::before{content:""}.si-stumbleupon::before{content:""}.si-delicious::before{content:""}.si-digg::before{content:""}.si-pied-piper::before{content:""}.si-pied-piper-alt::before{content:""}.si-drupal::before{content:""}.si-joomla::before{content:""}.si-language::before{content:""}.si-fax::before{content:""}.si-building::before{content:""}.si-child::before{content:""}.si-paw::before{content:""}.si-spoon::before{content:""}.si-cube::before{content:""}.si-cubes::before{content:""}.si-behance::before{content:""}.si-behance-square::before{content:""}.si-steam::before{content:""}.si-steam-square::before{content:""}.si-recycle::before{content:""}.si-automobile::before{content:""}.si-cab::before{content:""}.si-tree::before{content:""}.si-spotify::before{content:""}.si-deviantart::before{content:""}.si-soundcloud::before{content:""}.si-database::before{content:""}.si-file-pdf-o::before{content:""}.si-file-word-o::before{content:""}.si-file-excel-o::before{content:""}.si-file-powerpoint-o::before{content:""}.si-file-image-o::before{content:""}.si-file-archive-o::before{content:""}.si-file-audio-o::before{content:""}.si-file-movie-o::before{content:""}.si-file-code-o::before{content:""}.si-vine::before{content:""}.si-codepen::before{content:""}.si-jsfiddle::before{content:""}.si-life-bouy::before{content:""}.si-circle-o-notch::before{content:""}.si-ra::before{content:""}.si-empire::before{content:""}.si-git-square::before{content:""}.si-git::before{content:""}.si-hacker-news::before{content:""}.si-tencent-weibo::before{content:""}.si-qq::before{content:""}.si-wechat::before{content:""}.si-paper-plane::before{content:""}.si-paper-plane-o::before{content:""}.si-history::before{content:""}.si-circle-thin::before{content:""}.si-header::before{content:""}.si-paragraph::before{content:""}.si-sliders::before{content:""}.si-share-alt::before{content:""}.si-share-alt-square::before{content:""}.si-bomb::before{content:""}.si-futbol-o::before{content:""}.si-tty::before{content:""}.si-binoculars::before{content:""}.si-plug::before{content:""}.si-slideshare::before{content:""}.si-twitch::before{content:""}.si-yelp::before{content:""}.si-newspaper-o::before{content:""}.si-wifi::before{content:""}.si-calculator::before{content:""}.si-paypal::before{content:""}.si-google-wallet::before{content:""}.si-cc-visa::before{content:""}.si-cc-mastercard::before{content:""}.si-cc-discover::before{content:""}.si-cc-amex::before{content:""}.si-cc-paypal::before{content:""}.si-cc-stripe::before{content:""}.si-bell-slash::before{content:""}.si-bell-slash-o::before{content:""}.si-trash::before{content:""}.si-copyright::before{content:""}.si-at::before{content:""}.si-eyedropper::before{content:""}.si-paint-brush::before{content:""}.si-birthday-cake::before{content:""}.si-area-chart::before{content:""}.si-pie-chart::before{content:""}.si-line-chart::before{content:""}.si-lastfm::before{content:""}.si-lastfm-square::before{content:""}.si-toggle-off::before{content:""}.si-toggle-on::before{content:""}.si-bicycle::before{content:""}.si-bus::before{content:""}.si-ioxhost::before{content:""}.si-angellist::before{content:""}.si-cc::before{content:""}.si-ils::before{content:""}.si-meanpath::before{content:""}.si-buysellads::before{content:""}.si-connectdevelop::before{content:""}.si-dashcube::before{content:""}.si-forumbee::before{content:""}.si-leanpub::before{content:""}.si-sellsy::before{content:""}.si-shirtsinbulk::before{content:""}.si-simplybuilt::before{content:""}.si-skyatlas::before{content:""}.si-cart-plus::before{content:""}.si-cart-arrow-down::before{content:""}.si-diamond::before{content:""}.si-ship::before{content:""}.si-user-secret::before{content:""}.si-motorcycle::before{content:""}.si-street-view::before{content:""}.si-heartbeat::before{content:""}.si-venus::before{content:""}.si-mars::before{content:""}.si-mercury::before{content:""}.si-intersex::before{content:""}.si-transgender-alt::before{content:""}.si-venus-double::before{content:""}.si-mars-double::before{content:""}.si-venus-mars::before{content:""}.si-mars-stroke::before{content:""}.si-mars-stroke-v::before{content:""}.si-mars-stroke-h::before{content:""}.si-neuter::before{content:""}.si-genderless::before{content:""}.si-facebook-official::before{content:""}.si-pinterest-p::before{content:""}.si-whatsapp::before{content:""}.si-server::before{content:""}.si-user-plus::before{content:""}.si-user-times::before{content:""}.si-bed::before{content:""}.si-viacoin::before{content:""}.si-train::before{content:""}.si-subway::before{content:""}.si-medium::before{content:""}.si-y-combinator::before{content:""}.si-optin-monster::before{content:""}.si-opencart::before{content:""}.si-expeditedssl::before{content:""}.si-battery-4::before{content:""}.si-battery-3::before{content:""}.si-battery-2::before{content:""}.si-battery-1::before{content:""}.si-battery-0::before{content:""}.si-mouse-pointer::before{content:""}.si-i-cursor::before{content:""}.si-object-group::before{content:""}.si-object-ungroup::before{content:""}.si-sticky-note::before{content:""}.si-sticky-note-o::before{content:""}.si-cc-jcb::before{content:""}.si-cc-diners-club::before{content:""}.si-clone::before{content:""}.si-balance-scale::before{content:""}.si-hourglass-o::before{content:""}.si-hourglass-1::before{content:""}.si-hourglass-2::before{content:""}.si-hourglass-3::before{content:""}.si-hourglass::before{content:""}.si-hand-grab-o::before{content:""}.si-hand-paper-o::before{content:""}.si-hand-scissors-o::before{content:""}.si-hand-lizard-o::before{content:""}.si-hand-spock-o::before{content:""}.si-hand-pointer-o::before{content:""}.si-hand-peace-o::before{content:""}.si-trademark::before{content:""}.si-registered::before{content:""}.si-creative-commons::before{content:""}.si-gg::before{content:""}.si-gg-circle::before{content:""}.si-tripadvisor::before{content:""}.si-odnoklassniki::before{content:""}.si-odnoklassniki-square::before{content:""}.si-get-pocket::before{content:""}.si-wikipedia-w::before{content:""}.si-safari::before{content:""}.si-chrome::before{content:""}.si-firefox::before{content:""}.si-opera::before{content:""}.si-internet-explorer::before{content:""}.si-television::before{content:""}.si-contao::before{content:""}.si-500px::before{content:""}.si-amazon::before{content:""}.si-calendar-plus-o::before{content:""}.si-calendar-minus-o::before{content:""}.si-calendar-times-o::before{content:""}.si-calendar-check-o::before{content:""}.si-industry::before{content:""}.si-map-pin::before{content:""}.si-map-signs::before{content:""}.si-map-o::before{content:""}.si-map::before{content:""}.si-commenting::before{content:""}.si-commenting-o::before{content:""}.si-houzz::before{content:""}.si-vimeo::before{content:""}.si-black-tie::before{content:""}.si-fonticons::before{content:""}.si-lg{font-size:1.33333333em;line-height:0.75em;vertical-align:-15%}.si-2x{font-size:2em}.si-3x{font-size:3em}.si-4x{font-size:4em}.si-5x{font-size:5em}.si-fw{text-align:center;width:1.28571429em}.si-border{border-radius:.1em;padding:.2em .25em .15em;border:solid 0.08em}.si-pull-left{float:left;margin-right:.3em}.si-pull-right{float:right;margin-left:.3em}.si-rotate-90{-webkit-transform:rotate(90deg);-moz-transform:rotate(90deg);-ms-transform:rotate(90deg);-o-transform:rotate(90deg);transform:rotate(90deg)}.si-rotate-180{-webkit-transform:rotate(180deg);-moz-transform:rotate(180deg);-ms-transform:rotate(180deg);-o-transform:rotate(180deg);transform:rotate(180deg)}.si-rotate-270{-webkit-transform:rotate(270deg);-moz-transform:rotate(270deg);-ms-transform:rotate(270deg);-o-transform:rotate(270deg);transform:rotate(270deg)}.si-flip-horizontal{-webkit-transform:scale(-1, 1);-moz-transform:scale(-1, 1);-ms-transform:scale(-1, 1);-o-transform:scale(-1, 1);transform:scale(-1, 1)}.si-flip-vertical{-webkit-transform:scale(1, -1);-moz-transform:scale(1, -1);-ms-transform:scale(1, -1);-o-transform:scale(1, -1);transform:scale(1, -1)}.si-inverse{-webkit-filter:invert(100%);filter:invert(100%)}.si-spin{-webkit-animation:si-animation-spin 2s infinite linear;-moz-animation:si-animation-spin 2s infinite linear;animation:si-animation-spin 2s infinite linear}.si-pulse{-webkit-animation:si-animation-spin 1s infinite steps(8);-moz-animation:si-animation-spin 1s infinite steps(8);animation:si-animation-spin 1s infinite steps(8)}.si-ul{padding-left:0;list-style-type:none;margin-left:2.14285714em}.si-ul>li{position:relative}.si-ul>li .si-li{text-align:center;position:absolute;left:-2.14285714em;width:2.14285714em;top:0.14285714em}.si-ul>li .si-li .si-lg{left:-1.85714286em}.si-stack{width:2em;height:2em;line-height:2em;vertical-align:middle;position:relative;display:inline-block}.si-stack .si-stack-1x,.si-stack .si-stack-2x{left:0;width:100%;text-align:center;position:absolute}.si-stack .si-stack-1x{line-height:inherit}.si-stack .si-stack-2x{font-size:2em}@-webkit-keyframes si-animation-spin{0%{-webkit-transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg)}}@-moz-keyframes si-animation-spin{0%{-moz-transform:rotate(0deg)}100%{-moz-transform:rotate(359deg)}}@keyframes si-animation-spin{0%{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);-ms-transform:rotate(0deg);-o-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);-moz-transform:rotate(359deg);-ms-transform:rotate(359deg);-o-transform:rotate(359deg);transform:rotate(359deg)}}.plugin-menu-page-animation-spin{-webkit-animation-duration:0.75s;-moz-animation-duration:0.75s;animation-duration:0.75s;-webkit-animation-fill-mode:both;-moz-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:linear;-moz-animation-timing-function:linear;animation-timing-function:linear;-webkit-animation-iteration-count:infinite;-moz-animation-iteration-count:infinite;animation-iteration-count:infinite;-webkit-animation-name:plugin-menu-page-animation-spin;-moz-animation-name:plugin-menu-page-animation-spin;animation-name:plugin-menu-page-animation-spin}@-webkit-keyframes plugin-menu-page-animation-spin{0%{-webkit-transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg)}}@-moz-keyframes plugin-menu-page-animation-spin{0%{-moz-transform:rotate(0deg)}100%{-moz-transform:rotate(360deg)}}@keyframes plugin-menu-page-animation-spin{0%{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);-ms-transform:rotate(0deg);-o-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);-ms-transform:rotate(360deg);-o-transform:rotate(360deg);transform:rotate(360deg)}}html{overflow-y:scroll}#wpwrap{position:relative}#wpwrap::after{top:0;right:0;bottom:0;left:0;z-index:-1;position:absolute;content:'';opacity:0.25;background:url("../images/bg.png")}#wpwrap .updated,#wpwrap .error{margin:1.25em 1.25em 1.25em 0.25em}.plugin-menu-page{min-width:800px;margin:1.25em 1.25em 1.25em 0.25em}.plugin-menu-page,.plugin-menu-page p{font-size:14px}.plugin-menu-page a{color:#033A63}.plugin-menu-page a:hover,.plugin-menu-page a:active{color:#467629}.plugin-menu-page p:first-child,.plugin-menu-page pre:first-child{margin-top:0}.plugin-menu-page p:last-child,.plugin-menu-page pre:last-child{margin-bottom:0}.plugin-menu-page code{border-radius:3px;padding:0.1em 0.25em;background:rgba(178,178,178,0.25);font-family:'Menlo', 'Monaco', 'Consolas', 'Courier New', monospace}.plugin-menu-page pre.code{padding:0;background:none}.plugin-menu-page pre.code>code{font-size:90%;overflow-x:auto;max-width:100%;border-radius:4px;padding:1em;display:block;color:#eee;background:#222;box-shadow:0 0 5px 1px #000 inset}.plugin-menu-page img{border:0}.plugin-menu-page img.screenshot{float:right;border-radius:4px;padding:0.5em;margin:0 0 2em 2em;background:#fff;border:1px solid #afafaf;box-shadow:0 0 5px 0 rgba(0,0,0,0.2) inset}.plugin-menu-page hr{border:0;padding:0;height:1px;margin:1em 0;background:linear-gradient(to left, transparent, rgba(0,0,0,0.75), transparent)}.plugin-menu-page label{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.plugin-menu-page label.switch-primary{font-size:120%;margin:0;padding:0.5em;border-radius:4px;display:inline;color:#000;background:#f1e982;border:1px solid rgba(0,0,0,0.07);box-shadow:-1px -1px 0 0 rgba(0,0,0,0.25) inset,1px 1px 0 0 #fff inset}.plugin-menu-page select,.plugin-menu-page textarea,.plugin-menu-page select:focus,.plugin-menu-page textarea:focus,.plugin-menu-page input:not([type='radio']):not([type='checkbox']),.plugin-menu-page input:not([type='radio']):not([type='checkbox']):focus{width:100%;line-height:1.3em;margin:0;padding:0.25em 0.5em;border-radius:4px;box-sizing:border-box;color:#333;background:#e8e8e8;border:1px solid #848484;box-shadow:0 0 2px 0 rgba(132,132,132,0.5) inset}.plugin-menu-page select,.plugin-menu-page select:focus{box-shadow:0 1px 0 0 #fff inset,0 -2px 3px 0 rgba(132,132,132,0.25) inset}.plugin-menu-page select,.plugin-menu-page select:focus,.plugin-menu-page input:not([type='radio']):not([type='checkbox']),.plugin-menu-page input:not([type='radio']):not([type='checkbox']):focus{height:2em}.plugin-menu-page select:focus,.plugin-menu-page textarea:focus,.plugin-menu-page input:not([type='radio']):not([type='checkbox']):focus{color:#000;background:#e2e2e2}.plugin-menu-page input[disabled],.plugin-menu-page select[disabled],.plugin-menu-page textarea[disabled]{opacity:0.5}.plugin-menu-page input::-webkit-input-placeholder,.plugin-menu-page textarea::-webkit-input-placeholder{font-style:italic;color:rgba(0,0,0,0.2)}.plugin-menu-page input::-moz-placeholder,.plugin-menu-page textarea::-moz-placeholder{font-style:italic;color:rgba(0,0,0,0.2)}.plugin-menu-page input:-moz-placeholder,.plugin-menu-page textarea:-moz-placeholder{font-style:italic;color:rgba(0,0,0,0.2)}.plugin-menu-page input:-ms-input-placeholder,.plugin-menu-page textarea:-ms-input-placeholder{font-style:italic;color:rgba(0,0,0,0.2)}.plugin-menu-page table{margin:1em 0}.plugin-menu-page button{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;font-size:150%;font-weight:600;line-height:1em;outline:none;cursor:pointer;border-radius:4px;margin:0;padding:0.25em 0.5em;box-sizing:border-box;color:#fff;background:#033A63;border:1px solid rgba(0,0,0,0.5);box-shadow:0 1px 1px 0 rgba(0,0,0,0.25),-1px -1px 0 0 rgba(0,0,0,0.2) inset,1px 1px 0 0 rgba(255,255,255,0.1) inset}.plugin-menu-page button:hover{background:#467629}.plugin-menu-page button[type='submit']{background:#467629}.plugin-menu-page button[type='submit']:hover{background:#033A63}.plugin-menu-page button:active{-webkit-transform:scale(0.98, 0.98);-moz-transform:scale(0.98, 0.98);-ms-transform:scale(0.98, 0.98);-o-transform:scale(0.98, 0.98);transform:scale(0.98, 0.98)}.plugin-menu-page .info,.plugin-menu-page .notice,.plugin-menu-page .warning,.plugin-menu-page .error{border-radius:4px;padding:0.5em;margin:1em 0}.plugin-menu-page .info{background:#cadfed;border:1px solid #216095}.plugin-menu-page .notice{background:#fffde8;border:1px solid #e6db55}.plugin-menu-page .warning{background:#ffefd3;border:1px solid #e6db55}.plugin-menu-page .error{background:pink;border:1px solid #711e1e}.plugin-menu-page .monospace{font-family:'Menlo', 'Monaco', 'Consolas', 'Courier New', monospace}.plugin-menu-page textarea.monospace{white-space:pre}.plugin-menu-page .clearfix::before,.plugin-menu-page .clearfix::after{display:table;content:' '}.plugin-menu-page .clearfix::after{clear:both}.plugin-menu-page-heading .plugin-menu-page-restore-defaults,.plugin-menu-page-heading .plugin-menu-page-panel-togglers{float:right;margin:0 1em 0 0}.plugin-menu-page-heading .plugin-menu-page-panel-togglers button{background:#033A63 !important}.plugin-menu-page-heading .plugin-menu-page-upsells{float:right;clear:right;text-align:right;max-width:350px;margin:1em 0 0}.plugin-menu-page-heading .plugin-menu-page-upsells a{text-decoration:none;line-height:1.5em;margin:0 0.5em;display:inline-block}.plugin-menu-page-heading .plugin-menu-page-support-links,.plugin-menu-page-heading .plugin-menu-page-mailing-list-links{float:right;clear:right;text-align:right;max-width:400px;margin:.5em 0 0}.plugin-menu-page-heading .plugin-menu-page-support-links a,.plugin-menu-page-heading .plugin-menu-page-mailing-list-links a{text-decoration:none;margin:0 0.5em;display:inline-block}.plugin-menu-page-heading .plugin-menu-page-version{float:right;clear:right;min-width:350px;margin:0.5em 0 0 0;text-align:right}.plugin-menu-page-body{position:relative}.plugin-menu-page-section-heading{margin:1em 0}.plugin-menu-page-section-heading>small{font-size:65%;font-style:italic;margin:0;display:block;opacity:0.5}.plugin-menu-page-panel{margin:1em 0}.plugin-menu-page-panel:first-child{margin-top:0}.plugin-menu-page-panel .plugin-menu-page-panel-heading{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;text-decoration:none;padding:10px;font-size:150%;line-height:1.125em;font-weight:600;border-radius:4px;display:block;cursor:pointer;background:#033A63;background:linear-gradient(to right, #033A63, #20669A);color:#eee !important;box-shadow:0 2px 2px 0 rgba(0,0,0,0.25)}.plugin-menu-page-panel .plugin-menu-page-panel-heading::after{font:normal normal normal 14px/1 sharkicons;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;font-smoothing:antialiased;display:inline-block;font-size:inherit;text-decoration:inherit;text-transform:none;content:""}.plugin-menu-page-panel .plugin-menu-page-panel-heading:hover,.plugin-menu-page-panel .plugin-menu-page-panel-heading.open{color:#fff !important}.plugin-menu-page-panel .plugin-menu-page-panel-heading::after{font-size:80%;float:right;margin:0 0 0 5px}.plugin-menu-page-panel .plugin-menu-page-panel-heading.open::after{content:""}.plugin-menu-page-panel-heading.pro-preview-feature{background:#216095}.pro-preview-feature::after{font-variant:small-caps !important;font-family:sans-serif !important;content:'pro version only' !important;margin-left:15px;background:#216095;color:#FFFFFF;padding:0 5px 2px 5px;font-weight:normal}.plugin-menu-page-panel-heading.pro-preview-additional-features{background:#216095}.pro-preview-additional-features::after{font-variant:small-caps !important;font-family:sans-serif !important;content:'additional pro features' !important;margin-left:15px;background:#216095;color:#FFFFFF;padding:0 5px 2px 5px;font-weight:normal}.plugin-menu-page-panel .plugin-menu-page-panel-heading>.si{text-align:center;width:1.28571429em;margin-right:.25em}.plugin-menu-page-panel .plugin-menu-page-panel-body{width:99%;margin:0 auto;display:none;padding:1.2em;border-bottom-left-radius:4px;border-bottom-right-radius:4px;box-sizing:border-box;color:#222;border:1px solid #848484;background:#fff;box-shadow:0 1px 1px 0 rgba(0,0,0,0.25),0 3px 1px -1px rgba(0,0,0,0.25) inset}.plugin-menu-page-panel .plugin-menu-page-panel-body.open{display:block}.plugin-menu-page-panel .plugin-menu-page-panel-body p{font-size:13px;color:#666}.plugin-menu-page-panel .plugin-menu-page-panel-body p.notice,.plugin-menu-page-panel .plugin-menu-page-panel-body p.info,.plugin-menu-page-panel .plugin-menu-page-panel-body p.warning,.plugin-menu-page-panel .plugin-menu-page-panel-body p.error{color:#000}.plugin-menu-page-panel .plugin-menu-page-panel-body h3{margin:0 0 0.5em}.plugin-menu-page-panel .plugin-menu-page-panel-body h3:first-child{margin-top:0}.plugin-menu-page-panel .plugin-menu-page-panel-body h3+p{margin-top:0}.plugin-menu-page-panel .plugin-menu-page-panel-body a.dotted{text-decoration:none;border-bottom:1px dotted}.plugin-menu-page-panel .plugin-menu-page-panel-body.pro-preview,.plugin-menu-page-panel .plugin-menu-page-panel-body .pro-preview{opacity:0.5}.plugin-menu-page-save{margin-top:2em}.plugin-menu-page-save button{line-height:1.3em;width:100%}.plugin-menu-page-save-and-update{margin-top:2em}.plugin-menu-page-save-and-update button{line-height:1.3em;display:inline;width:45%;margin-left:1.5em}
|
2 |
|
src/client-s/js/admin-bar.js
ADDED
@@ -0,0 +1,134 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
(function ($) {
|
2 |
+
'use strict'; // Standards.
|
3 |
+
|
4 |
+
var plugin = {
|
5 |
+
namespace: 'comet_cache'
|
6 |
+
},
|
7 |
+
$window = $(window),
|
8 |
+
$document = $(document);
|
9 |
+
|
10 |
+
plugin.onReady = function () {
|
11 |
+
|
12 |
+
plugin.hideAJAXResponseTimeout = null;
|
13 |
+
plugin.vars = $('#' + plugin.namespace + '-admin-bar-vars').data('json');
|
14 |
+
|
15 |
+
$('#wp-admin-bar-' + plugin.namespace + '-wipe > a').on('click', plugin.wipeCache);
|
16 |
+
$('#wp-admin-bar-' + plugin.namespace + '-clear > a').on('click', plugin.clearCache);
|
17 |
+
|
18 |
+
$document.on('click', '.' + plugin.namespace + '-ajax-response', plugin.hideAJAXResponse);
|
19 |
+
|
20 |
+
};
|
21 |
+
|
22 |
+
plugin.wipeCache = function (event) {
|
23 |
+
plugin.preventDefault(event);
|
24 |
+
plugin.statsData = null;
|
25 |
+
|
26 |
+
var postVars = {
|
27 |
+
_wpnonce: plugin.vars._wpnonce
|
28 |
+
}; // HTTP post vars.
|
29 |
+
postVars[plugin.namespace] = {
|
30 |
+
ajaxWipeCache: '1'
|
31 |
+
};
|
32 |
+
var $wipe = $('#wp-admin-bar-' + plugin.namespace + '-wipe > a');
|
33 |
+
var $clearOptionsLabel = $('#wp-admin-bar-' + plugin.namespace + '-clear-options-wrapper .-label');
|
34 |
+
var $clearOptions = $('#wp-admin-bar-' + plugin.namespace + '-clear-options-wrapper .-options');
|
35 |
+
|
36 |
+
plugin.removeAJAXResponse();
|
37 |
+
$wipe.parent().addClass('-processing');
|
38 |
+
$wipe.add($clearOptions.find('a')).attr('disabled', 'disabled');
|
39 |
+
|
40 |
+
$.post(plugin.vars.ajaxURL, postVars, function (data) {
|
41 |
+
plugin.removeAJAXResponse();
|
42 |
+
$wipe.parent().removeClass('-processing');
|
43 |
+
$wipe.add($clearOptions.find('a')).removeAttr('disabled');
|
44 |
+
|
45 |
+
var $response = $('<div class="' + plugin.namespace + '-ajax-response -wipe">' + data + '</div>');
|
46 |
+
$('body').append($response); // Append response.
|
47 |
+
plugin.showAJAXResponse(); // Show response.
|
48 |
+
});
|
49 |
+
};
|
50 |
+
|
51 |
+
plugin.clearCache = function (event, options) {
|
52 |
+
plugin.preventDefault(event);
|
53 |
+
|
54 |
+
|
55 |
+
var postVars = {
|
56 |
+
_wpnonce: plugin.vars._wpnonce
|
57 |
+
}; // HTTP post vars.
|
58 |
+
|
59 |
+
var isClearOption = false;
|
60 |
+
|
61 |
+
{
|
62 |
+
postVars[plugin.namespace] = {
|
63 |
+
ajaxClearCache: '1'
|
64 |
+
};
|
65 |
+
}
|
66 |
+
var $clear = $('#wp-admin-bar-' + plugin.namespace + '-clear > a');
|
67 |
+
|
68 |
+
plugin.removeAJAXResponse();
|
69 |
+
|
70 |
+
if (isClearOption && $clearOptionsLabel.length) {
|
71 |
+
$clearOptionsLabel.addClass('-processing');
|
72 |
+
} else {
|
73 |
+
$clear.parent().addClass('-processing');
|
74 |
+
}
|
75 |
+
$clear.add($clearOptions.find('a')).attr('disabled', 'disabled');
|
76 |
+
|
77 |
+
$.post(plugin.vars.ajaxURL, postVars, function (data) {
|
78 |
+
plugin.removeAJAXResponse();
|
79 |
+
|
80 |
+
if (isClearOption && $clearOptionsLabel.length) {
|
81 |
+
$clearOptionsLabel.removeClass('-processing');
|
82 |
+
} else {
|
83 |
+
$clear.parent().removeClass('-processing');
|
84 |
+
}
|
85 |
+
$clear.add($clearOptions.find('a')).removeAttr('disabled');
|
86 |
+
|
87 |
+
var $response = $('<div class="' + plugin.namespace + '-ajax-response -clear">' + data + '</div>');
|
88 |
+
$('body').append($response); // Append response.
|
89 |
+
plugin.showAJAXResponse(); // Show response.
|
90 |
+
});
|
91 |
+
};
|
92 |
+
|
93 |
+
|
94 |
+
plugin.showAJAXResponse = function () {
|
95 |
+
clearTimeout(plugin.hideAJAXResponseTimeout);
|
96 |
+
|
97 |
+
$('.' + plugin.namespace + '-ajax-response')
|
98 |
+
.off(plugin.animationEndEvents) // Reattaching below.
|
99 |
+
.on(plugin.animationEndEvents, function () { // Reattach.
|
100 |
+
plugin.hideAJAXResponseTimeout = setTimeout(plugin.hideAJAXResponse, 2500);
|
101 |
+
})
|
102 |
+
.addClass(plugin.namespace + '-admin-bar-animation-zoom-in-down').show()
|
103 |
+
.on('mouseover', function () { // Do not auto-hide if hovered.
|
104 |
+
clearTimeout(plugin.hideAJAXResponseTimeout);
|
105 |
+
$(this).addClass('-hovered');
|
106 |
+
});
|
107 |
+
};
|
108 |
+
|
109 |
+
plugin.hideAJAXResponse = function (event) {
|
110 |
+
plugin.preventDefault(event);
|
111 |
+
|
112 |
+
clearTimeout(plugin.hideAJAXResponseTimeout);
|
113 |
+
|
114 |
+
$('.' + plugin.namespace + '-ajax-response')
|
115 |
+
.off(plugin.animationEndEvents) // Reattaching below.
|
116 |
+
.on(plugin.animationEndEvents, function () { // Reattach.
|
117 |
+
plugin.removeAJAXResponse(); // Remove completely.
|
118 |
+
})
|
119 |
+
.addClass(plugin.namespace + '-admin-bar-animation-zoom-out-up');
|
120 |
+
};
|
121 |
+
|
122 |
+
plugin.removeAJAXResponse = function () {
|
123 |
+
clearTimeout(plugin.hideAJAXResponseTimeout);
|
124 |
+
|
125 |
+
$('.' + plugin.namespace + '-ajax-response')
|
126 |
+
.off(plugin.animationEndEvents).remove();
|
127 |
+
};
|
128 |
+
|
129 |
+
plugin.animationEndEvents = // All vendor prefixes.
|
130 |
+
'webkitAnimationEnd mozAnimationEnd msAnimationEnd oAnimationEnd animationEnd';
|
131 |
+
|
132 |
+
$document.ready(plugin.onReady); // On DOM ready.
|
133 |
+
|
134 |
+
})(jQuery);
|
src/client-s/js/admin-bar.min.js
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
(function(b){var a={namespace:"comet_cache"},d=b(window),c=b(document);a.onReady=function(){a.statsData=null;a.statsRunning=false;a.hideAJAXResponseTimeout=null;a.vars=b("#"+a.namespace+"-admin-bar-vars").data("json");b("#wp-admin-bar-"+a.namespace+"-wipe > a").on("click",a.wipeCache);b("#wp-admin-bar-"+a.namespace+"-clear > a").on("click",a.clearCache);b("#wp-admin-bar-"+a.namespace+"-clear-options-wrapper .-home-url-only > a").on("click",a.clearCacheHomeUrlOnly);b("#wp-admin-bar-"+a.namespace+"-clear-options-wrapper .-current-url-only > a").on("click",a.clearCacheCurrentUrlOnly);b("#wp-admin-bar-"+a.namespace+"-clear-options-wrapper .-specific-url-only > a").on("click",a.clearCacheSpecificUrlOnly);b("#wp-admin-bar-"+a.namespace+"-clear-options-wrapper .-opcache-only > a").on("click",a.clearCacheOpCacheOnly);b("#wp-admin-bar-"+a.namespace+"-clear-options-wrapper .-cdn-only > a").on("click",a.clearCacheCdnOnly);b("#wp-admin-bar-"+a.namespace+"-clear-options-wrapper .-transients-only > a").on("click",a.clearExpiredTransientsOnly);c.on("click","."+a.namespace+"-ajax-response",a.hideAJAXResponse);var f=b("#wp-admin-bar-"+a.namespace+"-stats"),e=f.find(".-wrapper"),g=e.find(".-container");if(f.length&&a.MutationObserver){(new a.MutationObserver(function(h){b.each(h,function(k,i){if(i.type!=="attributes"){return}if(i.attributeName!=="class"){return}var j=i.oldValue,l=b(i.target).prop(i.attributeName);if(!/\bhover\b/i.test(j)&&/\bhover\b/i.test(l)){a.stats()}return false})})).observe(f[0],{attributes:true,attributeOldValue:true,childList:true,characterData:true})}};a.wipeCache=function(i){a.preventDefault(i);a.statsData=null;var f={_wpnonce:a.vars._wpnonce};f[a.namespace]={ajaxWipeCache:"1"};var e=b("#wp-admin-bar-"+a.namespace+"-wipe > a");var h=b("#wp-admin-bar-"+a.namespace+"-clear-options-wrapper .-label");var g=b("#wp-admin-bar-"+a.namespace+"-clear-options-wrapper .-options");a.removeAJAXResponse();e.parent().addClass("-processing");e.add(g.find("a")).attr("disabled","disabled");b.post(a.vars.ajaxURL,f,function(k){a.removeAJAXResponse();e.parent().removeClass("-processing");e.add(g.find("a")).removeAttr("disabled");var j=b('<div class="'+a.namespace+'-ajax-response -wipe">'+k+"</div>");b("body").append(j);a.showAJAXResponse()})};a.clearCache=function(j,f){a.preventDefault(j);a.statsData=null;f=f||{};var l=b.extend({},{urlOnly:"",opCacheOnly:false,cdnOnly:false,transientsOnly:false},f);var e={_wpnonce:a.vars._wpnonce};var i=false;if(l.urlOnly){i=true;e[a.namespace]={ajaxClearCacheUrl:l.urlOnly}}else{if(l.opCacheOnly){i=true;e[a.namespace]={ajaxClearOpCache:"1"}}else{if(l.cdnOnly){i=true;e[a.namespace]={ajaxClearCdnCache:"1"}}else{if(l.transientsOnly){i=true;e[a.namespace]={ajaxClearExpiredTransients:"1"}}else{e[a.namespace]={ajaxClearCache:"1"}}}}}var k=b("#wp-admin-bar-"+a.namespace+"-clear > a");var h=b("#wp-admin-bar-"+a.namespace+"-clear-options-wrapper .-label");var g=b("#wp-admin-bar-"+a.namespace+"-clear-options-wrapper .-options");a.removeAJAXResponse();if(i&&h.length){h.addClass("-processing")}else{k.parent().addClass("-processing")}k.add(g.find("a")).attr("disabled","disabled");b.post(a.vars.ajaxURL,e,function(n){a.removeAJAXResponse();if(i&&h.length){h.removeClass("-processing")}else{k.parent().removeClass("-processing")}k.add(g.find("a")).removeAttr("disabled");var m=b('<div class="'+a.namespace+'-ajax-response -clear">'+n+"</div>");b("body").append(m);a.showAJAXResponse()})};a.clearCacheHomeUrlOnly=function(e){a.clearCache(e,{urlOnly:"home"})};a.clearCacheCurrentUrlOnly=function(e){a.clearCache(e,{urlOnly:document.URL})};a.clearCacheSpecificUrlOnly=function(f){var e=b.trim(prompt(a.vars.i18n.enterSpecificUrl,"http://"));if(e&&e!=="http://"){a.clearCache(f,{urlOnly:e})}else{a.preventDefault(f)}};a.clearCacheOpCacheOnly=function(e){a.clearCache(e,{opCacheOnly:true})};a.clearCacheCdnOnly=function(e){a.clearCache(e,{cdnOnly:true})};a.clearExpiredTransientsOnly=function(e){a.clearCache(e,{transientsOnly:true})};a.showAJAXResponse=function(){clearTimeout(a.hideAJAXResponseTimeout);b("."+a.namespace+"-ajax-response").off(a.animationEndEvents).on(a.animationEndEvents,function(){a.hideAJAXResponseTimeout=setTimeout(a.hideAJAXResponse,2500)}).addClass(a.namespace+"-admin-bar-animation-zoom-in-down").show().on("mouseover",function(){clearTimeout(a.hideAJAXResponseTimeout);b(this).addClass("-hovered")})};a.hideAJAXResponse=function(e){a.preventDefault(e);clearTimeout(a.hideAJAXResponseTimeout);b("."+a.namespace+"-ajax-response").off(a.animationEndEvents).on(a.animationEndEvents,function(){a.removeAJAXResponse()}).addClass(a.namespace+"-admin-bar-animation-zoom-out-up")};a.removeAJAXResponse=function(){clearTimeout(a.hideAJAXResponseTimeout);b("."+a.namespace+"-ajax-response").off(a.animationEndEvents).remove()};a.stats=function(){if(a.statsRunning){return}a.statsRunning=true;var t=!a.vars.isMultisite||a.vars.currentUserHasNetworkCap;var p=b("body"),o=b("#wp-admin-bar-"+a.namespace+"-stats"),s=o.find(".-wrapper"),q=s.find(".-container"),e=q.find(".-refreshing"),g=q.find(".-chart-a"),f=q.find(".-chart-b"),i=q.find(".-totals"),k=i.find(".-files"),r=i.find(".-size"),j=i.find(".-dir"),h=q.find(".-disk"),l=h.find(".-free"),m=h.find(".-size"),n=q.find(".-more-info");var u=function(){if(!o.hasClass("hover")){a.statsRunning=false;return}e.show();g.hide();f.hide();i.removeClass("-no-charts");i.css("visibility","hidden");if(!t||b.trim(j.text()).length>30){j.hide()}h.css("visibility","hidden");if(t){n.css("visibility","hidden")}else{n.hide()}if(!a.statsData){var w={_wpnonce:a.vars._wpnonce};w[a.namespace]={ajaxDirStats:"1"};b.post(a.vars.ajaxURL,w,function(x){console.log("Admin Bar :: statsData :: %o",x);a.statsData=x;v()})}else{setTimeout(v,500)}},v=function(){if(!a.statsData){a.statsRunning=false;return}if(!o.hasClass("hover")){a.statsRunning=false;return}e.hide();g.css("display","block");f.css("display","block");var Y=null,X=null,T=null,Z=null;var x=t?"forCache":"forHostCache",M=t?"forHtmlCCache":"forHtmlCHostCache",B=t?"largestCacheSize":"largestHostCacheSize",z=t?"largestCacheCount":"largestHostCacheCount";var C=a.statsData[B].size,L=a.statsData[B].days,E=a.statsData[z].count,S=a.statsData[z].days,R=a.statsData[x].stats.total_links_files,aa=a.statsData[M].stats.total_links_files,F=R+aa,J=a.statsData[x].stats.total_size,O=a.statsData[M].stats.total_size,P=J+O,N=a.statsData[x].stats.disk_total_space,K=a.statsData[x].stats.disk_free_space,G=0,W=0,w=0,I=0,D=0,Q=0;if(a.vars.isMultisite&&a.vars.currentUserHasNetworkCap){G=a.statsData.forHostCache.stats.total_links_files;W=a.statsData.forHtmlCHostCache.stats.total_links_files;w=G+W;I=a.statsData.forHostCache.stats.total_size;D=a.statsData.forHtmlCHostCache.stats.total_size;Q=I+D}var y=function(af,ad){if(!(af instanceof Array)){return{}}if(typeof ad!=="number"||ad<=0){ad=10}var ac=[];b.each(af,function(ai,aj){ac.push(Number(aj.value))});var ah=0,ae=Math.min.apply(null,ac),ab=Math.max.apply(null,ac),ag=Math.ceil((ab-ah)/ad);return{scaleSteps:ad,scaleStartValue:ah,scaleStepWidth:ag,scaleIntegersOnly:true,scaleOverride:true}},H={responsive:true,maintainAspectRatio:true,animationSteps:35,scaleFontSize:10,scaleShowLine:true,scaleFontFamily:"sans-serif",scaleShowLabelBackdrop:true,scaleBackdropPaddingY:2,scaleBackdropPaddingX:4,scaleFontColor:"rgba(0,0,0,1)",scaleBackdropColor:"rgba(255,255,255,1)",scaleLineColor:b("body").hasClass("admin-color-light")?"rgba(0,0,0,0.25)":"rgba(255,255,255,0.25)",scaleLabel:function(ab){return a.bytesToSizeLabel(Number(ab.value))},tooltipFontSize:12,tooltipFillColor:"rgba(0,0,0,1)",tooltipFontFamily:"Georgia, serif",tooltipTemplate:function(ab){return ab.label+": "+a.bytesToSizeLabel(Number(ab.value))},segmentShowStroke:true,segmentStrokeWidth:1,segmentStrokeColor:b("body").hasClass("admin-color-light")?"rgba(0,0,0,1)":"rgba(255,255,255,1)"},V=H;var A=[],U=[];A.push({value:C,label:a.vars.i18n.xDayHigh.replace("%s",L),color:"#ff5050",highlight:"#c63f3f"});A.push({value:P,label:a.vars.i18n.currentTotal,color:"#46bf52",highlight:"#33953e"});A.push({value:J,label:a.vars.i18n.pageCache,color:"#0096CC",highlight:"#057ca7"});A.push({value:O,label:a.vars.i18n.htmlCompressor,color:"#FFC870",highlight:"#d6a85d"});if(a.vars.isMultisite&&a.vars.currentUserHasNetworkCap){A.push({value:Q,label:a.vars.i18n.currentSite,color:"#46bfb4",highlight:"#348f87"})}b.extend(H,y(A,5));U=A;b.extend(V,y(U,5));if((Y=o.data("chartA"))){Y.destroy()}if((X=o.data("chartB"))){X.destroy()}if((T=o.data("chartADimensions"))){g.attr("width",parseInt(T.width)).attr("height",parseInt(T.height)).css(T)}if((Z=o.data("chartBDimensions"))){f.attr("width",parseInt(Z.width)).attr("height",parseInt(Z.height)).css(Z)}if(g.length&&A[0].value>0){Y=new Chart(g[0].getContext("2d")).PolarArea(A,H);o.data("chartA",Y).data("chartADimensions",{width:g.width()+"px",height:g.height()+"px"})}else{Y=null;g.hide()}if(f.length&&U[0].value>0){X=new Chart(f[0].getContext("2d")).PolarArea(U,V);o.data("chartB",X).data("chartBDimensions",{width:f.width()+"px",height:f.height()+"px"})}else{X=null;f.hide()}if(!Y&&!X){i.addClass("-no-charts")}i.css("visibility","visible");k.find(".-value").html(a.escHtml(a.numberFormat(F)+" "+(F===1?a.vars.i18n.file:a.vars.i18n.files)));r.find(".-value").html(a.escHtml(a.bytesToSizeLabel(P)));h.css("visibility","visible");m.find(".-value").html(a.escHtml(a.bytesToSizeLabel(N)));l.find(".-value").html(a.escHtml(a.bytesToSizeLabel(K)));if(t){n.css("visibility","visible")}a.statsRunning=false};u()};a.bytesToSizeLabel=function(f,e){if(typeof f!=="number"||f<=1){return f===1?"1 byte":"0 bytes"}if(typeof e!=="number"||e<=0){e=0}var i=1024,j=Math.floor(Math.log(f)/Math.log(i)),h=["bytes","KB","MB","GB","TB","PB","EB","ZB","YB"],g=(f/Math.pow(i,j));return g.toFixed(e)+" "+h[j]};a.numberFormat=function(f,e){if(typeof f!=="number"){return String(f)}if(typeof e!=="number"||e<=0){e=0}return f.toFixed(e).replace(/./g,function(g,i,h){return i&&g!=="."&&((h.length-i)%3===0)?","+g:g})};a.escHtml=function(f){var e={"&":"&","<":"<",">":">",'"':""","'":"'"};return String(f).replace(/[&<>"']/g,function(g){return e[g]})};a.preventDefault=function(f,e){if(!f){return}f.preventDefault();if(e){f.stopImmediatePropagation()}};a.MutationObserver=(function(){var e=null;b.each(["","WebKit","O","Moz","Ms"],function(f,g){if(g+"MutationObserver" in window){e=window[g+"MutationObserver"];return false}});return e}());a.animationEndEvents="webkitAnimationEnd mozAnimationEnd msAnimationEnd oAnimationEnd animationEnd";c.ready(a.onReady)})(jQuery);
|
src/includes/classes/Actions.php
CHANGED
@@ -19,7 +19,8 @@ class Actions extends AbsBase
|
|
19 |
|
20 |
|
21 |
|
22 |
-
|
|
|
23 |
|
24 |
|
25 |
|
@@ -34,8 +35,6 @@ class Actions extends AbsBase
|
|
34 |
|
35 |
|
36 |
|
37 |
-
|
38 |
-
|
39 |
'dismissNotice',
|
40 |
];
|
41 |
|
@@ -113,9 +112,62 @@ class Actions extends AbsBase
|
|
113 |
wp_redirect($redirect_to).exit();
|
114 |
}
|
115 |
|
116 |
-
|
117 |
|
118 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
119 |
|
120 |
|
121 |
|
@@ -271,8 +323,6 @@ class Actions extends AbsBase
|
|
271 |
|
272 |
|
273 |
|
274 |
-
|
275 |
-
|
276 |
/**
|
277 |
* Action handler.
|
278 |
*
|
19 |
|
20 |
|
21 |
|
22 |
+
'ajaxWipeCache',
|
23 |
+
'ajaxClearCache',
|
24 |
|
25 |
|
26 |
|
35 |
|
36 |
|
37 |
|
|
|
|
|
38 |
'dismissNotice',
|
39 |
];
|
40 |
|
112 |
wp_redirect($redirect_to).exit();
|
113 |
}
|
114 |
|
|
|
115 |
|
116 |
+
/**
|
117 |
+
* Action handler.
|
118 |
+
*
|
119 |
+
* @since 150422 Rewrite.
|
120 |
+
*
|
121 |
+
* @param mixed Input action argument(s).
|
122 |
+
*/
|
123 |
+
protected function ajaxWipeCache($args)
|
124 |
+
{
|
125 |
+
if (!is_multisite() || !$this->plugin->currentUserCanWipeCache()) {
|
126 |
+
return; // Nothing to do.
|
127 |
+
}
|
128 |
+
if (empty($_REQUEST['_wpnonce']) || !wp_verify_nonce($_REQUEST['_wpnonce'])) {
|
129 |
+
return; // Unauthenticated POST data.
|
130 |
+
}
|
131 |
+
$counter = $this->plugin->wipeCache(true);
|
132 |
+
|
133 |
+
|
134 |
+
$response = sprintf(__('<p>Wiped a total of <code>%2$s</code> cache files.</p>', 'comet-cache'), esc_html(NAME), esc_html($counter));
|
135 |
+
$response .= __('<p>Cache wiped for all sites. Re-creation will occur automatically over time.</p>', 'comet-cache');
|
136 |
+
|
137 |
+
|
138 |
+
exit($response); // JavaScript will take it from here.
|
139 |
+
}
|
140 |
+
|
141 |
+
|
142 |
+
|
143 |
+
/**
|
144 |
+
* Action handler.
|
145 |
+
*
|
146 |
+
* @since 150422 Rewrite.
|
147 |
+
*
|
148 |
+
* @param mixed Input action argument(s).
|
149 |
+
*/
|
150 |
+
protected function ajaxClearCache($args)
|
151 |
+
{
|
152 |
+
if (!$this->plugin->currentUserCanClearCache()) {
|
153 |
+
return; // Not allowed to clear.
|
154 |
+
}
|
155 |
+
if (empty($_REQUEST['_wpnonce']) || !wp_verify_nonce($_REQUEST['_wpnonce'])) {
|
156 |
+
return; // Unauthenticated POST data.
|
157 |
+
}
|
158 |
+
$counter = $this->plugin->clearCache(true);
|
159 |
+
|
160 |
+
$response = sprintf(__('<p>Cleared a total of <code>%2$s</code> cache files.</p>', 'comet-cache'), esc_html(NAME), esc_html($counter));
|
161 |
+
|
162 |
+
if (is_multisite() && is_main_site()) {
|
163 |
+
$response .= __('<p>Cache cleared for main site. Re-creation will occur automatically over time.</p>', 'comet-cache');
|
164 |
+
} else {
|
165 |
+
$response .= __('<p>Cache cleared for this site. Re-creation will occur automatically over time.</p>', 'comet-cache');
|
166 |
+
}
|
167 |
+
|
168 |
+
exit($response); // JavaScript will take it from here.
|
169 |
+
}
|
170 |
+
|
171 |
|
172 |
|
173 |
|
323 |
|
324 |
|
325 |
|
|
|
|
|
326 |
/**
|
327 |
* Action handler.
|
328 |
*
|
src/includes/classes/MenuPage.php
CHANGED
@@ -28,8 +28,6 @@ class MenuPage extends AbsBase
|
|
28 |
break;
|
29 |
|
30 |
|
31 |
-
|
32 |
-
|
33 |
}
|
34 |
}
|
35 |
}
|
28 |
break;
|
29 |
|
30 |
|
|
|
|
|
31 |
}
|
32 |
}
|
33 |
}
|
src/includes/classes/MenuPageOptions.php
CHANGED
@@ -48,7 +48,6 @@ class MenuPageOptions extends MenuPage
|
|
48 |
|
49 |
echo ' <div class="plugin-menu-page-upsells">'."\n";
|
50 |
if (IS_PRO && current_user_can($this->plugin->update_cap)) {
|
51 |
-
echo '<a href="'.esc_attr(add_query_arg(urlencode_deep(['page' => GLOBAL_NS.'-pro-updater']), self_admin_url('/admin.php'))).'"><i class="si si-magic"></i> '.__('Pro Updater', 'comet-cache').'</a>'."\n";
|
52 |
echo '<a href="'.esc_attr('http://cometcache.com/r/comet-cache-subscribe/').'" target="_blank"><i class="si si-envelope"></i> '.__('Newsletter', 'comet-cache').'</a>'."\n";
|
53 |
echo '<a href="'.esc_attr('http://cometcache.com/r/comet-cache-beta-testers-list/').'" target="_blank"><i class="si si-envelope"></i> '.__('Beta Testers', 'comet-cache').'</a>'."\n";
|
54 |
}
|
@@ -69,7 +68,6 @@ class MenuPageOptions extends MenuPage
|
|
69 |
echo ' <a href="'.esc_attr('http://cometcache.com/blog/').'" target="_blank"><i class="si si-rss-square"></i> '.__('Blog', 'comet-cache').'</a>'."\n";
|
70 |
echo ' </div>'."\n";
|
71 |
|
72 |
-
|
73 |
echo ' <div class="plugin-menu-page-mailing-list-links">'."\n";
|
74 |
if (!IS_PRO) { // We show these above in the Pro version
|
75 |
echo ' <a href="'.esc_attr('http://cometcache.com/r/comet-cache-subscribe/').'" target="_blank"><i class="si si-envelope"></i> '.__('Newsletter', 'comet-cache').'</a>'."\n";
|
@@ -79,13 +77,16 @@ class MenuPageOptions extends MenuPage
|
|
79 |
echo ' <a href="'.esc_attr('https://www.facebook.com/cometcache/').'" target="_blank"><i class="si si-facebook"></i> '.__('Facebook', 'comet-cache').'</a>'."\n";
|
80 |
echo ' </div>'."\n";
|
81 |
|
82 |
-
|
83 |
if (IS_PRO) {
|
84 |
echo '<div class="plugin-menu-page-version">'."\n";
|
85 |
echo ' '.sprintf(__('%1$s™ Pro v%2$s', 'comet-cache'), esc_html(NAME), esc_html(VERSION))."\n";
|
86 |
|
87 |
if ($this->plugin->options['latest_pro_version'] && version_compare(VERSION, $this->plugin->options['latest_pro_version'], '<')) {
|
88 |
-
|
|
|
|
|
|
|
|
|
89 |
} else {
|
90 |
echo '(<a href="'.esc_attr('https://cometcache.com/changelog/').'" target="_blank">'.__('changelog', 'comet-cache').'</a>)'."\n";
|
91 |
}
|
@@ -125,15 +126,15 @@ class MenuPageOptions extends MenuPage
|
|
125 |
}
|
126 |
if (!empty($_REQUEST[GLOBAL_NS.'_cache_wiped'])) {
|
127 |
echo '<div class="plugin-menu-page-notice notice">'."\n";
|
128 |
-
echo ' <img src="'.esc_attr($this->plugin->url('/src/client-s/images/wipe.png')).'" /> '.__('Cache wiped across all sites;
|
129 |
echo '</div>'."\n";
|
130 |
}
|
131 |
if (!empty($_REQUEST[GLOBAL_NS.'_cache_cleared'])) {
|
132 |
echo '<div class="plugin-menu-page-notice notice">'."\n";
|
133 |
if (is_multisite() && is_main_site()) {
|
134 |
-
echo '<img src="'.esc_attr($this->plugin->url('/src/client-s/images/clear.png')).'" /> '.__('Cache cleared for main site;
|
135 |
} else {
|
136 |
-
echo '<img src="'.esc_attr($this->plugin->url('/src/client-s/images/clear.png')).'" /> '.__('Cache cleared for this site;
|
137 |
}
|
138 |
echo '</div>'."\n";
|
139 |
}
|
@@ -154,12 +155,12 @@ class MenuPageOptions extends MenuPage
|
|
154 |
}
|
155 |
if (!empty($_REQUEST[GLOBAL_NS.'_wp_config_wp_cache_add_failure'])) {
|
156 |
echo '<div class="plugin-menu-page-notice error">'."\n";
|
157 |
-
echo ' <i class="si si-thumbs-down"></i> '.__('Failed to update your <code>/wp-config.php</code> file automatically. Please add the following line to your <code>/wp-config.php</code> file (right after the opening <code><?php</code> tag; on it\'s own line). <pre class="code"><code>define(\'WP_CACHE\',
|
158 |
echo '</div>'."\n";
|
159 |
}
|
160 |
if (!empty($_REQUEST[GLOBAL_NS.'_wp_config_wp_cache_remove_failure'])) {
|
161 |
echo '<div class="plugin-menu-page-notice error">'."\n";
|
162 |
-
echo ' <i class="si si-thumbs-down"></i> '.__('Failed to update your <code>/wp-config.php</code> file automatically. Please remove the following line from your <code>/wp-config.php</code> file, or set <code>WP_CACHE</code> to a <code>FALSE</code> value. <pre class="code"><code>define(\'WP_CACHE\',
|
163 |
echo '</div>'."\n";
|
164 |
}
|
165 |
if (!empty($_REQUEST[GLOBAL_NS.'_advanced_cache_add_failure'])) {
|
@@ -228,6 +229,43 @@ class MenuPageOptions extends MenuPage
|
|
228 |
|
229 |
/* ----------------------------------------------------------------------------------------- */
|
230 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
231 |
echo '<div class="plugin-menu-page-panel">'."\n";
|
232 |
|
233 |
echo ' <a href="#" class="plugin-menu-page-panel-heading">'."\n";
|
@@ -865,6 +903,9 @@ class MenuPageOptions extends MenuPage
|
|
865 |
echo ' <div class="plugin-menu-page-panel-body clearfix">'."\n";
|
866 |
echo ' <i class="si si-question-circle si-4x" style="float:right; margin: 0 0 0 25px;"></i>'."\n";
|
867 |
echo ' <h3>'.__('Enable WebSharks™ HTML Compression?', 'comet-cache').'</h3>'."\n";
|
|
|
|
|
|
|
868 |
echo ' <p><select name="'.esc_attr(GLOBAL_NS).'[saveOptions][htmlc_enable]" data-target=".-htmlc-options">'."\n";
|
869 |
echo ' <option value="0"'.(!IS_PRO ? '' : selected($this->plugin->options['htmlc_enable'], '0', false)).'>'.__('No, do NOT compress HTML/CSS/JS code at runtime.', 'comet-cache').'</option>'."\n";
|
870 |
echo ' <option value="1"'.(!IS_PRO ? ' selected' : selected($this->plugin->options['htmlc_enable'], '1', false)).'>'.__('Yes, I want to compress HTML/CSS/JS for blazing fast speeds.', 'comet-cache').'</option>'."\n";
|
@@ -1035,7 +1076,6 @@ class MenuPageOptions extends MenuPage
|
|
1035 |
/* ----------------------------------------------------------------------------------------- */
|
1036 |
|
1037 |
if ($is_apache || $this->plugin->isProPreview()) {
|
1038 |
-
|
1039 |
echo '<div class="plugin-menu-page-panel'.(!IS_PRO && $this->plugin->isProPreview() ? ' pro-preview' : '').'">'."\n";
|
1040 |
|
1041 |
echo ' <a href="#" class="plugin-menu-page-panel-heading'.((!IS_PRO && $this->plugin->isProPreview()) ? ' pro-preview-additional-features' : '').'">'."\n";
|
@@ -1066,14 +1106,14 @@ class MenuPageOptions extends MenuPage
|
|
1066 |
|
1067 |
if ((!IS_PRO && $is_apache) && !$this->plugin->isProPreview()) {
|
1068 |
echo ' <hr />'."\n";
|
1069 |
-
echo ' <p class="warning" style="display:block;">'.__('<a href="
|
1070 |
}
|
1071 |
|
1072 |
if (IS_PRO || $this->plugin->isProPreview()) {
|
1073 |
echo ' <hr />'."\n";
|
1074 |
echo ' <h3 class="'.(!IS_PRO ? 'pro-preview-feature' : '').'">'.__('Leverage Browser Caching?', 'comet-cache').'</h3>'."\n";
|
1075 |
echo ' <p>'.__('<a href="https://cometcache.com/r/google-developers-http-caching/" target="_blank">Browser Caching</a> is highly recommended. When loading a single page, downloading all of the resources for that page may require multiple roundtrips between the browser and server, which delays processing and may block rendering of page content. This also incurs data costs for the visitor. With browser caching, your server tells the visitor\'s browser that it is allowed to cache static resources for a certain amount of time (Google recommends 1 week and that\'s what Comet Cache uses).', 'comet-cache').'</p>'."\n";
|
1076 |
-
echo ' <p>'.__('In WordPress, \'Page Caching\' is all about server-side performance (reducing the amount of time it takes the server to generate the page content). With Comet Cache installed, you\'re drastically reducing page generation time. However, you can make a
|
1077 |
echo ' <p><select name="'.esc_attr(GLOBAL_NS).'[saveOptions][htaccess_browser_caching_enable]" data-target=".-htaccess-browser-caching-enable-options">'."\n";
|
1078 |
echo ' <option value="0"'.(!IS_PRO ? '' : selected($this->plugin->options['htaccess_browser_caching_enable'], '0', false)).'>'.__('No, do NOT enable Browser Caching (or I\'ll update my configuration manually; see below)', 'comet-cache').'</option>'."\n";
|
1079 |
echo ' <option value="1"'.(!IS_PRO ? 'selected' : selected($this->plugin->options['htaccess_browser_caching_enable'], '1', false)).'>'.__('Yes, enable Browser Caching for static resources (recommended)', 'comet-cache').'</option>'."\n";
|
@@ -1123,7 +1163,6 @@ class MenuPageOptions extends MenuPage
|
|
1123 |
}
|
1124 |
echo ' </div>'."\n";
|
1125 |
echo '</div>'."\n";
|
1126 |
-
|
1127 |
}
|
1128 |
|
1129 |
/* ----------------------------------------------------------------------------------------- */
|
48 |
|
49 |
echo ' <div class="plugin-menu-page-upsells">'."\n";
|
50 |
if (IS_PRO && current_user_can($this->plugin->update_cap)) {
|
|
|
51 |
echo '<a href="'.esc_attr('http://cometcache.com/r/comet-cache-subscribe/').'" target="_blank"><i class="si si-envelope"></i> '.__('Newsletter', 'comet-cache').'</a>'."\n";
|
52 |
echo '<a href="'.esc_attr('http://cometcache.com/r/comet-cache-beta-testers-list/').'" target="_blank"><i class="si si-envelope"></i> '.__('Beta Testers', 'comet-cache').'</a>'."\n";
|
53 |
}
|
68 |
echo ' <a href="'.esc_attr('http://cometcache.com/blog/').'" target="_blank"><i class="si si-rss-square"></i> '.__('Blog', 'comet-cache').'</a>'."\n";
|
69 |
echo ' </div>'."\n";
|
70 |
|
|
|
71 |
echo ' <div class="plugin-menu-page-mailing-list-links">'."\n";
|
72 |
if (!IS_PRO) { // We show these above in the Pro version
|
73 |
echo ' <a href="'.esc_attr('http://cometcache.com/r/comet-cache-subscribe/').'" target="_blank"><i class="si si-envelope"></i> '.__('Newsletter', 'comet-cache').'</a>'."\n";
|
77 |
echo ' <a href="'.esc_attr('https://www.facebook.com/cometcache/').'" target="_blank"><i class="si si-facebook"></i> '.__('Facebook', 'comet-cache').'</a>'."\n";
|
78 |
echo ' </div>'."\n";
|
79 |
|
|
|
80 |
if (IS_PRO) {
|
81 |
echo '<div class="plugin-menu-page-version">'."\n";
|
82 |
echo ' '.sprintf(__('%1$s™ Pro v%2$s', 'comet-cache'), esc_html(NAME), esc_html(VERSION))."\n";
|
83 |
|
84 |
if ($this->plugin->options['latest_pro_version'] && version_compare(VERSION, $this->plugin->options['latest_pro_version'], '<')) {
|
85 |
+
if (!$this->plugin->options['pro_update_username'] || !$this->plugin->options['pro_update_password']) {
|
86 |
+
echo '(<a href="#" style="font-weight:bold;" onclick="alert(\''.sprintf(__('A username and license key are required to complete an upgrade. See: %1$s → Plugin Options → \\\'Authentication for Automatic Updates\\\'. Enter the required details and try again.', 'comet-cache'), NAME).'\'); return false;">'.__('update available', 'comet-cache').'</a>)'."\n";
|
87 |
+
} else {
|
88 |
+
echo '(<a href="'.esc_attr(self_admin_url('/update-core.php')).'" style="font-weight:bold;">'.__('update available', 'comet-cache').'</a>)'."\n";
|
89 |
+
}
|
90 |
} else {
|
91 |
echo '(<a href="'.esc_attr('https://cometcache.com/changelog/').'" target="_blank">'.__('changelog', 'comet-cache').'</a>)'."\n";
|
92 |
}
|
126 |
}
|
127 |
if (!empty($_REQUEST[GLOBAL_NS.'_cache_wiped'])) {
|
128 |
echo '<div class="plugin-menu-page-notice notice">'."\n";
|
129 |
+
echo ' <img src="'.esc_attr($this->plugin->url('/src/client-s/images/wipe.png')).'" /> '.__('Cache wiped across all sites; re-creation will occur automatically over time.', 'comet-cache')."\n";
|
130 |
echo '</div>'."\n";
|
131 |
}
|
132 |
if (!empty($_REQUEST[GLOBAL_NS.'_cache_cleared'])) {
|
133 |
echo '<div class="plugin-menu-page-notice notice">'."\n";
|
134 |
if (is_multisite() && is_main_site()) {
|
135 |
+
echo '<img src="'.esc_attr($this->plugin->url('/src/client-s/images/clear.png')).'" /> '.__('Cache cleared for main site; re-creation will occur automatically over time.', 'comet-cache')."\n";
|
136 |
} else {
|
137 |
+
echo '<img src="'.esc_attr($this->plugin->url('/src/client-s/images/clear.png')).'" /> '.__('Cache cleared for this site; re-creation will occur automatically over time.', 'comet-cache')."\n";
|
138 |
}
|
139 |
echo '</div>'."\n";
|
140 |
}
|
155 |
}
|
156 |
if (!empty($_REQUEST[GLOBAL_NS.'_wp_config_wp_cache_add_failure'])) {
|
157 |
echo '<div class="plugin-menu-page-notice error">'."\n";
|
158 |
+
echo ' <i class="si si-thumbs-down"></i> '.__('Failed to update your <code>/wp-config.php</code> file automatically. Please add the following line to your <code>/wp-config.php</code> file (right after the opening <code><?php</code> tag; on it\'s own line). <pre class="code"><code>define( \'WP_CACHE\', true );</code></pre>', 'comet-cache')."\n";
|
159 |
echo '</div>'."\n";
|
160 |
}
|
161 |
if (!empty($_REQUEST[GLOBAL_NS.'_wp_config_wp_cache_remove_failure'])) {
|
162 |
echo '<div class="plugin-menu-page-notice error">'."\n";
|
163 |
+
echo ' <i class="si si-thumbs-down"></i> '.__('Failed to update your <code>/wp-config.php</code> file automatically. Please remove the following line from your <code>/wp-config.php</code> file, or set <code>WP_CACHE</code> to a <code>FALSE</code> value. <pre class="code"><code>define( \'WP_CACHE\', true );</code></pre>', 'comet-cache')."\n";
|
164 |
echo '</div>'."\n";
|
165 |
}
|
166 |
if (!empty($_REQUEST[GLOBAL_NS.'_advanced_cache_add_failure'])) {
|
229 |
|
230 |
/* ----------------------------------------------------------------------------------------- */
|
231 |
|
232 |
+
if (IS_PRO || $this->plugin->isProPreview()) {
|
233 |
+
echo '<div class="plugin-menu-page-panel">'."\n";
|
234 |
+
|
235 |
+
echo ' <a href="#" class="plugin-menu-page-panel-heading'.(!IS_PRO ? ' pro-preview-feature' : '').'">'."\n";
|
236 |
+
echo ' <i class="si si-sign-in"></i> '.__('Update Credentials', 'comet-cache')."\n";
|
237 |
+
echo ' </a>'."\n";
|
238 |
+
|
239 |
+
echo ' <div class="plugin-menu-page-panel-body clearfix">'."\n";
|
240 |
+
|
241 |
+
echo ' <i class="si si-user si-4x" style="float:right; margin: 0 0 0 25px;"></i>'."\n";
|
242 |
+
|
243 |
+
echo ' <h3>'.__('Authentication for Automatic Updates', 'comet-cache').'</h3>'."\n";
|
244 |
+
echo ' <p>'.sprintf(__('%1$s Pro is a premium product available for purchase @ <a href="http://cometcache.com/prices/" target="_blank">cometcache.com</a>. In order to connect with our update servers, you must supply your License Key. Your License Key is located under "My Account" when you log in @ <a href="http://cometcache.com/" target="_blank">cometcache.com</a>. This will authenticate your copy of %1$s Pro; providing you with access to the latest version. You only need to enter these credentials once. %1$s Pro will save them in your WordPress database; making future upgrades even easier. <i class="si si-smile-o"></i> If you prefer to upgrade manually, see <a href="https://cometcache.com/r/kb-article-how-to-manually-upgrade-comet-cache-pro/">this article</a>.', 'comet-cache'), esc_html(NAME)).'</p>'."\n";
|
245 |
+
echo ' <hr />'."\n";
|
246 |
+
|
247 |
+
echo ' <h3>'.sprintf(__('Username', 'comet-cache'), esc_html(NAME)).'</h3>'."\n";
|
248 |
+
echo ' <p><input type="text" name="'.esc_attr(GLOBAL_NS).'[saveOptions][pro_update_username]" value="'.esc_attr($this->plugin->options['pro_update_username']).'" autocomplete="new-password" /></p>'."\n";
|
249 |
+
echo ' <h3>'.sprintf(__('License Key', 'comet-cache'), esc_html(NAME)).'</h3>'."\n";
|
250 |
+
echo ' <p><input type="password" name="'.esc_attr(GLOBAL_NS).'[saveOptions][pro_update_password]" value="'.esc_attr($this->plugin->options['pro_update_password']).'" autocomplete="new-password" /></p>'."\n";
|
251 |
+
|
252 |
+
echo ' <hr />'."\n";
|
253 |
+
echo ' <h3>'.__('Beta Program', 'comet-cache').'</h3>'."\n";
|
254 |
+
echo ' <p>'.sprintf(__('If you would like to participate in our beta program and receive new features and bug fixes before they are released to the public, %1$s can include Release Candidates when checking for automatic updates. Release Candidates are almost-ready-for-production and have already been through many internal test runs. Our team runs the latest Release Candidate on all of our production sites, but that doesn\'t mean you\'ll want to do the same. :-) Please report any issues with Release Candidates on <a href="https://github.com/websharks/comet-cache/issues/" target="_blank">GitHub</a>.', 'comet-cache'), esc_html(NAME)).'</p>'."\n";
|
255 |
+
|
256 |
+
echo ' <p><select name="'.esc_attr(GLOBAL_NS).'[saveOptions][pro_update_check_stable]" autocomplete="off">'."\n";
|
257 |
+
echo ' <option value="1"'.selected($this->plugin->options['pro_update_check_stable'], '1', false).'>'.sprintf(__('No, do not check for Release Candidates; I only want public releases.', 'comet-cache'), esc_html(NAME)).'</option>'."\n";
|
258 |
+
echo ' <option value="0"'.selected($this->plugin->options['pro_update_check_stable'], '0', false).'>'.sprintf(__('Yes, check for Release Candidates; I want to help with testing.', 'comet-cache'), esc_html(NAME)).'</option>'."\n";
|
259 |
+
echo ' </select></p>'."\n";
|
260 |
+
echo ' <p class="info" style="display:block;">'.__('<strong>How will I know that I\'m running a Release Candidate?</strong><br />If you\'re running a Release Candidate, the version ends with <code>-RC</code>, e.g., Comet Cache™ Pro v151201-RC.', 'comet-cache').'</p>'."\n";
|
261 |
+
echo ' <p class="info" style="display:block;">'.__('<strong>Email Alternative:</strong> Instead, if you\'d just like to receive updates about Release Candidates (via email), including a Release Candidate changelog, please sign up for the <a href="http://cometcache.com/r/comet-cache-beta-testers-list/" target="_blank">beta testers mailing list</a>.', 'comet-cache').'</p>'."\n";
|
262 |
+
|
263 |
+
echo ' </div>'."\n";
|
264 |
+
|
265 |
+
echo '</div>'."\n";
|
266 |
+
}
|
267 |
+
/* ----------------------------------------------------------------------------------------- */
|
268 |
+
|
269 |
echo '<div class="plugin-menu-page-panel">'."\n";
|
270 |
|
271 |
echo ' <a href="#" class="plugin-menu-page-panel-heading">'."\n";
|
903 |
echo ' <div class="plugin-menu-page-panel-body clearfix">'."\n";
|
904 |
echo ' <i class="si si-question-circle si-4x" style="float:right; margin: 0 0 0 25px;"></i>'."\n";
|
905 |
echo ' <h3>'.__('Enable WebSharks™ HTML Compression?', 'comet-cache').'</h3>'."\n";
|
906 |
+
if (is_plugin_active('autoptimize/autoptimize.php')) {
|
907 |
+
echo ' <p class="warning">'.__('<strong>Autoptimize + Comet Cache:</strong> Comet Cache has detected that you are running the Autoptimize plugin. Autoptimize and the HTML Compressor feature of Comet Cache are both designed to compress HTML, CSS, and JavaScript. Enabling the HTML Compressor alongside Autoptimize may result in unexpected behavior. If you\'re happy with Autoptimize, you can leave the HTML Compressor disabled. All other Comet Cache features run great alongside Autoptimize.', 'comet-cache').' <i class="si si-smile-o"></i></p>';
|
908 |
+
}
|
909 |
echo ' <p><select name="'.esc_attr(GLOBAL_NS).'[saveOptions][htmlc_enable]" data-target=".-htmlc-options">'."\n";
|
910 |
echo ' <option value="0"'.(!IS_PRO ? '' : selected($this->plugin->options['htmlc_enable'], '0', false)).'>'.__('No, do NOT compress HTML/CSS/JS code at runtime.', 'comet-cache').'</option>'."\n";
|
911 |
echo ' <option value="1"'.(!IS_PRO ? ' selected' : selected($this->plugin->options['htmlc_enable'], '1', false)).'>'.__('Yes, I want to compress HTML/CSS/JS for blazing fast speeds.', 'comet-cache').'</option>'."\n";
|
1076 |
/* ----------------------------------------------------------------------------------------- */
|
1077 |
|
1078 |
if ($is_apache || $this->plugin->isProPreview()) {
|
|
|
1079 |
echo '<div class="plugin-menu-page-panel'.(!IS_PRO && $this->plugin->isProPreview() ? ' pro-preview' : '').'">'."\n";
|
1080 |
|
1081 |
echo ' <a href="#" class="plugin-menu-page-panel-heading'.((!IS_PRO && $this->plugin->isProPreview()) ? ' pro-preview-additional-features' : '').'">'."\n";
|
1106 |
|
1107 |
if ((!IS_PRO && $is_apache) && !$this->plugin->isProPreview()) {
|
1108 |
echo ' <hr />'."\n";
|
1109 |
+
echo ' <p class="warning" style="display:block;">'.sprintf(__('<a href="%1$s">Enable the Pro Preview</a> to see <strong>Leverage Browser Caching</strong>, <strong>Enforce Canonical URLs</strong>, and more!', 'comet-cache'), esc_attr(add_query_arg(urlencode_deep(['page' => GLOBAL_NS, GLOBAL_NS.'_pro_preview' => '1']), self_admin_url('/admin.php')))).'</p>'."\n";
|
1110 |
}
|
1111 |
|
1112 |
if (IS_PRO || $this->plugin->isProPreview()) {
|
1113 |
echo ' <hr />'."\n";
|
1114 |
echo ' <h3 class="'.(!IS_PRO ? 'pro-preview-feature' : '').'">'.__('Leverage Browser Caching?', 'comet-cache').'</h3>'."\n";
|
1115 |
echo ' <p>'.__('<a href="https://cometcache.com/r/google-developers-http-caching/" target="_blank">Browser Caching</a> is highly recommended. When loading a single page, downloading all of the resources for that page may require multiple roundtrips between the browser and server, which delays processing and may block rendering of page content. This also incurs data costs for the visitor. With browser caching, your server tells the visitor\'s browser that it is allowed to cache static resources for a certain amount of time (Google recommends 1 week and that\'s what Comet Cache uses).', 'comet-cache').'</p>'."\n";
|
1116 |
+
echo ' <p>'.__('In WordPress, \'Page Caching\' is all about server-side performance (reducing the amount of time it takes the server to generate the page content). With Comet Cache installed, you\'re drastically reducing page generation time. However, you can make a visitor\'s experience <em>even faster</em> when you leverage browser caching too. When this option is enabled, the visitor\'s browser will cache static resources from each page and reuse those cached resources on subsequent page loads. In this way, future visits to the same page will not require additional connections to your site to download static resources that the visitor\'s browser has already cached.', 'comet-cache').'</p>'."\n";
|
1117 |
echo ' <p><select name="'.esc_attr(GLOBAL_NS).'[saveOptions][htaccess_browser_caching_enable]" data-target=".-htaccess-browser-caching-enable-options">'."\n";
|
1118 |
echo ' <option value="0"'.(!IS_PRO ? '' : selected($this->plugin->options['htaccess_browser_caching_enable'], '0', false)).'>'.__('No, do NOT enable Browser Caching (or I\'ll update my configuration manually; see below)', 'comet-cache').'</option>'."\n";
|
1119 |
echo ' <option value="1"'.(!IS_PRO ? 'selected' : selected($this->plugin->options['htaccess_browser_caching_enable'], '1', false)).'>'.__('Yes, enable Browser Caching for static resources (recommended)', 'comet-cache').'</option>'."\n";
|
1163 |
}
|
1164 |
echo ' </div>'."\n";
|
1165 |
echo '</div>'."\n";
|
|
|
1166 |
}
|
1167 |
|
1168 |
/* ----------------------------------------------------------------------------------------- */
|
src/includes/classes/Plugin.php
CHANGED
@@ -13,6 +13,7 @@ class Plugin extends AbsBaseAp
|
|
13 |
{
|
14 |
/*[.build.php-auto-generate-use-Traits]*/
|
15 |
use Traits\Plugin\ActionUtils;
|
|
|
16 |
use Traits\Plugin\BbPressUtils;
|
17 |
use Traits\Plugin\CleanupUtils;
|
18 |
use Traits\Plugin\CondUtils;
|
@@ -50,7 +51,7 @@ class Plugin extends AbsBaseAp
|
|
50 |
*
|
51 |
* @since 150422 Rewrite.
|
52 |
*
|
53 |
-
* @
|
54 |
*/
|
55 |
public $enable_hooks = true;
|
56 |
|
@@ -59,7 +60,7 @@ class Plugin extends AbsBaseAp
|
|
59 |
*
|
60 |
* @since 150422 Rewrite.
|
61 |
*
|
62 |
-
* @
|
63 |
*/
|
64 |
public $pro_only_option_keys = [];
|
65 |
|
@@ -68,7 +69,7 @@ class Plugin extends AbsBaseAp
|
|
68 |
*
|
69 |
* @since 150422 Rewrite.
|
70 |
*
|
71 |
-
* @
|
72 |
*/
|
73 |
public $default_options = [];
|
74 |
|
@@ -77,7 +78,7 @@ class Plugin extends AbsBaseAp
|
|
77 |
*
|
78 |
* @since 150422 Rewrite.
|
79 |
*
|
80 |
-
* @
|
81 |
*/
|
82 |
public $options = [];
|
83 |
|
@@ -86,7 +87,7 @@ class Plugin extends AbsBaseAp
|
|
86 |
*
|
87 |
* @since 150422 Rewrite.
|
88 |
*
|
89 |
-
* @
|
90 |
*/
|
91 |
public $cap = 'activate_plugins';
|
92 |
|
@@ -95,7 +96,7 @@ class Plugin extends AbsBaseAp
|
|
95 |
*
|
96 |
* @since 150422 Rewrite.
|
97 |
*
|
98 |
-
* @
|
99 |
*/
|
100 |
public $update_cap = 'update_plugins';
|
101 |
|
@@ -104,7 +105,7 @@ class Plugin extends AbsBaseAp
|
|
104 |
*
|
105 |
* @since 150422 Rewrite.
|
106 |
*
|
107 |
-
* @
|
108 |
*/
|
109 |
public $network_cap = 'manage_network_plugins';
|
110 |
|
@@ -113,7 +114,7 @@ class Plugin extends AbsBaseAp
|
|
113 |
*
|
114 |
* @since 150422 Rewrite.
|
115 |
*
|
116 |
-
* @
|
117 |
*/
|
118 |
public $uninstall_cap = 'delete_plugins';
|
119 |
|
@@ -126,7 +127,7 @@ class Plugin extends AbsBaseAp
|
|
126 |
*
|
127 |
* @since 150422 Rewrite.
|
128 |
*
|
129 |
-
* @
|
130 |
*/
|
131 |
public $cache_sub_dir = 'cache';
|
132 |
|
@@ -180,7 +181,6 @@ class Plugin extends AbsBaseAp
|
|
180 |
|
181 |
'change_notifications_enable',
|
182 |
|
183 |
-
'cache_clear_admin_bar_enable',
|
184 |
'cache_clear_admin_bar_options_enable',
|
185 |
'cache_clear_admin_bar_roles_caps',
|
186 |
|
@@ -244,10 +244,14 @@ class Plugin extends AbsBaseAp
|
|
244 |
|
245 |
'pro_update_check',
|
246 |
'pro_update_check_stable',
|
247 |
-
'latest_pro_version',
|
248 |
'last_pro_update_check',
|
|
|
|
|
|
|
|
|
249 |
'pro_update_username',
|
250 |
'pro_update_password',
|
|
|
251 |
'last_pro_stats_log',
|
252 |
];
|
253 |
$this->default_options = [
|
@@ -412,9 +416,11 @@ class Plugin extends AbsBaseAp
|
|
412 |
|
413 |
'pro_update_check' => '1', // `0|1`; enable?
|
414 |
'pro_update_check_stable' => '1', // `0` for beta/RC checks; defaults to `1`
|
415 |
-
'latest_pro_version' => VERSION, // Latest version.
|
416 |
'last_pro_update_check' => '0', // Timestamp.
|
417 |
|
|
|
|
|
|
|
418 |
'pro_update_username' => '', // Username.
|
419 |
'pro_update_password' => '', // Password or license key.
|
420 |
|
@@ -453,9 +459,17 @@ class Plugin extends AbsBaseAp
|
|
453 |
|
454 |
|
455 |
|
456 |
-
|
457 |
|
458 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
459 |
|
460 |
add_action('admin_enqueue_scripts', [$this, 'enqueueAdminStyles']);
|
461 |
add_action('admin_enqueue_scripts', [$this, 'enqueueAdminScripts']);
|
13 |
{
|
14 |
/*[.build.php-auto-generate-use-Traits]*/
|
15 |
use Traits\Plugin\ActionUtils;
|
16 |
+
use Traits\Plugin\AdminBarUtils;
|
17 |
use Traits\Plugin\BbPressUtils;
|
18 |
use Traits\Plugin\CleanupUtils;
|
19 |
use Traits\Plugin\CondUtils;
|
51 |
*
|
52 |
* @since 150422 Rewrite.
|
53 |
*
|
54 |
+
* @var bool If `FALSE`, run without hooks.
|
55 |
*/
|
56 |
public $enable_hooks = true;
|
57 |
|
60 |
*
|
61 |
* @since 150422 Rewrite.
|
62 |
*
|
63 |
+
* @var array Pro-only option keys.
|
64 |
*/
|
65 |
public $pro_only_option_keys = [];
|
66 |
|
69 |
*
|
70 |
* @since 150422 Rewrite.
|
71 |
*
|
72 |
+
* @var array Default options.
|
73 |
*/
|
74 |
public $default_options = [];
|
75 |
|
78 |
*
|
79 |
* @since 150422 Rewrite.
|
80 |
*
|
81 |
+
* @var array Configured options.
|
82 |
*/
|
83 |
public $options = [];
|
84 |
|
87 |
*
|
88 |
* @since 150422 Rewrite.
|
89 |
*
|
90 |
+
* @var string WordPress capability.
|
91 |
*/
|
92 |
public $cap = 'activate_plugins';
|
93 |
|
96 |
*
|
97 |
* @since 150422 Rewrite.
|
98 |
*
|
99 |
+
* @var string WordPress capability.
|
100 |
*/
|
101 |
public $update_cap = 'update_plugins';
|
102 |
|
105 |
*
|
106 |
* @since 150422 Rewrite.
|
107 |
*
|
108 |
+
* @var string WordPress capability.
|
109 |
*/
|
110 |
public $network_cap = 'manage_network_plugins';
|
111 |
|
114 |
*
|
115 |
* @since 150422 Rewrite.
|
116 |
*
|
117 |
+
* @var string WordPress capability.
|
118 |
*/
|
119 |
public $uninstall_cap = 'delete_plugins';
|
120 |
|
127 |
*
|
128 |
* @since 150422 Rewrite.
|
129 |
*
|
130 |
+
* @var string Cache directory; relative to the configured base directory.
|
131 |
*/
|
132 |
public $cache_sub_dir = 'cache';
|
133 |
|
181 |
|
182 |
'change_notifications_enable',
|
183 |
|
|
|
184 |
'cache_clear_admin_bar_options_enable',
|
185 |
'cache_clear_admin_bar_roles_caps',
|
186 |
|
244 |
|
245 |
'pro_update_check',
|
246 |
'pro_update_check_stable',
|
|
|
247 |
'last_pro_update_check',
|
248 |
+
|
249 |
+
'latest_pro_version',
|
250 |
+
'latest_pro_package',
|
251 |
+
|
252 |
'pro_update_username',
|
253 |
'pro_update_password',
|
254 |
+
|
255 |
'last_pro_stats_log',
|
256 |
];
|
257 |
$this->default_options = [
|
416 |
|
417 |
'pro_update_check' => '1', // `0|1`; enable?
|
418 |
'pro_update_check_stable' => '1', // `0` for beta/RC checks; defaults to `1`
|
|
|
419 |
'last_pro_update_check' => '0', // Timestamp.
|
420 |
|
421 |
+
'latest_pro_version' => VERSION, // Latest version.
|
422 |
+
'latest_pro_package' => '', // Latest package URL.
|
423 |
+
|
424 |
'pro_update_username' => '', // Username.
|
425 |
'pro_update_password' => '', // Password or license key.
|
426 |
|
459 |
|
460 |
|
461 |
|
|
|
462 |
|
463 |
+
add_action('admin_bar_menu', [$this, 'adminBarMenu']);
|
464 |
+
add_action('wp_head', [$this, 'adminBarMetaTags'], 0);
|
465 |
+
add_action('wp_enqueue_scripts', [$this, 'adminBarStyles']);
|
466 |
+
add_action('wp_enqueue_scripts', [$this, 'adminBarScripts']);
|
467 |
+
|
468 |
+
|
469 |
+
add_action('admin_head', [$this, 'adminBarMetaTags'], 0);
|
470 |
+
add_action('admin_enqueue_scripts', [$this, 'adminBarStyles']);
|
471 |
+
add_action('admin_enqueue_scripts', [$this, 'adminBarScripts']);
|
472 |
+
|
473 |
|
474 |
add_action('admin_enqueue_scripts', [$this, 'enqueueAdminStyles']);
|
475 |
add_action('admin_enqueue_scripts', [$this, 'enqueueAdminScripts']);
|
src/includes/classes/VsUpgrades.php
CHANGED
@@ -43,6 +43,7 @@ class VsUpgrades extends AbsBase
|
|
43 |
$this->fromZenCache();
|
44 |
$this->fromLte160227();
|
45 |
$this->fromLte160521();
|
|
|
46 |
}
|
47 |
|
48 |
/**
|
@@ -76,7 +77,7 @@ class VsUpgrades extends AbsBase
|
|
76 |
if (is_array($existing_options = get_site_option(GLOBAL_NS.'_options'))) {
|
77 |
if (isset($existing_options['admin_bar_enable'])) {
|
78 |
$this->plugin->options['cache_clear_admin_bar_enable'] = $existing_options['admin_bar_enable'];
|
79 |
-
$this->plugin->updateOptions($this->plugin->options); // Save/update options.
|
80 |
}
|
81 |
}
|
82 |
}
|
@@ -115,7 +116,7 @@ class VsUpgrades extends AbsBase
|
|
115 |
$this->plugin->options['cdn_blacklisted_extensions'] = $this->plugin->default_options['cdn_blacklisted_extensions'];
|
116 |
}
|
117 |
if ($this->plugin->options !== $existing_options) {
|
118 |
-
$this->plugin->updateOptions($this->plugin->options); // Save/update options.
|
119 |
$this->plugin->activate(); // Reactivate plugin w/ new options.
|
120 |
}
|
121 |
}
|
@@ -196,7 +197,7 @@ class VsUpgrades extends AbsBase
|
|
196 |
$this->plugin->options['base_dir'] = $this->plugin->default_options['base_dir'];
|
197 |
$this->plugin->options['crons_setup'] = $this->plugin->default_options['crons_setup'];
|
198 |
|
199 |
-
$this->plugin->updateOptions($this->plugin->options); // Save/update options.
|
200 |
$this->plugin->activate(); // Reactivate plugin w/ new options.
|
201 |
|
202 |
$this->plugin->enqueueMainNotice(
|
@@ -218,7 +219,7 @@ class VsUpgrades extends AbsBase
|
|
218 |
if (is_array($existing_options = get_site_option(GLOBAL_NS.'_options'))) {
|
219 |
$this->plugin->options['cache_clear_term_other_enable'] = $this->plugin->default_options['cache_clear_term_other_enable'];
|
220 |
if ($this->plugin->options !== $existing_options) {
|
221 |
-
$this->plugin->updateOptions($this->plugin->options); // Save/update options.
|
222 |
$this->plugin->activate(); // Reactivate plugin w/ new options.
|
223 |
}
|
224 |
}
|
@@ -249,7 +250,7 @@ class VsUpgrades extends AbsBase
|
|
249 |
$this->plugin->options['htaccess_access_control_allow_origin'] = $existing_options['cdn_enable'];
|
250 |
}
|
251 |
if ($this->plugin->options !== $existing_options) {
|
252 |
-
$this->plugin->updateOptions($this->plugin->options); // Save/update options.
|
253 |
$this->plugin->activate(); // Reactivate plugin w/ new options.
|
254 |
}
|
255 |
}
|
@@ -259,4 +260,16 @@ class VsUpgrades extends AbsBase
|
|
259 |
}
|
260 |
}
|
261 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
262 |
}
|
43 |
$this->fromZenCache();
|
44 |
$this->fromLte160227();
|
45 |
$this->fromLte160521();
|
46 |
+
$this->fromLte160709();
|
47 |
}
|
48 |
|
49 |
/**
|
77 |
if (is_array($existing_options = get_site_option(GLOBAL_NS.'_options'))) {
|
78 |
if (isset($existing_options['admin_bar_enable'])) {
|
79 |
$this->plugin->options['cache_clear_admin_bar_enable'] = $existing_options['admin_bar_enable'];
|
80 |
+
$this->plugin->updateOptions($this->plugin->options, false); // Save/update options.
|
81 |
}
|
82 |
}
|
83 |
}
|
116 |
$this->plugin->options['cdn_blacklisted_extensions'] = $this->plugin->default_options['cdn_blacklisted_extensions'];
|
117 |
}
|
118 |
if ($this->plugin->options !== $existing_options) {
|
119 |
+
$this->plugin->updateOptions($this->plugin->options, false); // Save/update options.
|
120 |
$this->plugin->activate(); // Reactivate plugin w/ new options.
|
121 |
}
|
122 |
}
|
197 |
$this->plugin->options['base_dir'] = $this->plugin->default_options['base_dir'];
|
198 |
$this->plugin->options['crons_setup'] = $this->plugin->default_options['crons_setup'];
|
199 |
|
200 |
+
$this->plugin->updateOptions($this->plugin->options, false); // Save/update options.
|
201 |
$this->plugin->activate(); // Reactivate plugin w/ new options.
|
202 |
|
203 |
$this->plugin->enqueueMainNotice(
|
219 |
if (is_array($existing_options = get_site_option(GLOBAL_NS.'_options'))) {
|
220 |
$this->plugin->options['cache_clear_term_other_enable'] = $this->plugin->default_options['cache_clear_term_other_enable'];
|
221 |
if ($this->plugin->options !== $existing_options) {
|
222 |
+
$this->plugin->updateOptions($this->plugin->options, false); // Save/update options.
|
223 |
$this->plugin->activate(); // Reactivate plugin w/ new options.
|
224 |
}
|
225 |
}
|
250 |
$this->plugin->options['htaccess_access_control_allow_origin'] = $existing_options['cdn_enable'];
|
251 |
}
|
252 |
if ($this->plugin->options !== $existing_options) {
|
253 |
+
$this->plugin->updateOptions($this->plugin->options, false); // Save/update options.
|
254 |
$this->plugin->activate(); // Reactivate plugin w/ new options.
|
255 |
}
|
256 |
}
|
260 |
}
|
261 |
}
|
262 |
}
|
263 |
+
|
264 |
+
/**
|
265 |
+
* Before we replaced the Pro Plugin Updater system with the WordPress Plugin Update system.
|
266 |
+
*
|
267 |
+
* @since 160917
|
268 |
+
*/
|
269 |
+
protected function fromLte160709()
|
270 |
+
{
|
271 |
+
if (version_compare($this->prev_version, '160709', '<=')) {
|
272 |
+
$this->plugin->dismissMainNotice('new-pro-version-available'); // Dismiss any existing notices like this; upgrade notices are handled by WordPress now.
|
273 |
+
}
|
274 |
+
}
|
275 |
}
|
src/includes/stub.php
CHANGED
@@ -13,7 +13,7 @@ if (!defined('WPINC')) {
|
|
13 |
require_once dirname(__DIR__).'/vendor/autoload.php';
|
14 |
require_once __DIR__.'/functions/i18n-utils.php';
|
15 |
|
16 |
-
${__FILE__}['version'] = '
|
17 |
${__FILE__}['plugin'] = dirname(dirname(__DIR__));
|
18 |
${__FILE__}['plugin'] .= '/'.basename(${__FILE__}['plugin']).'.php';
|
19 |
${__FILE__}['ns_path'] = str_replace('\\', '/', __NAMESPACE__); // To dir/path.
|
13 |
require_once dirname(__DIR__).'/vendor/autoload.php';
|
14 |
require_once __DIR__.'/functions/i18n-utils.php';
|
15 |
|
16 |
+
${__FILE__}['version'] = '160917'; //version//
|
17 |
${__FILE__}['plugin'] = dirname(dirname(__DIR__));
|
18 |
${__FILE__}['plugin'] .= '/'.basename(${__FILE__}['plugin']).'.php';
|
19 |
${__FILE__}['ns_path'] = str_replace('\\', '/', __NAMESPACE__); // To dir/path.
|
src/includes/templates/{advanced-cache.txt → advanced-cache.x-php}
RENAMED
File without changes
|
src/includes/traits/Plugin/AdminBarUtils.php
ADDED
@@ -0,0 +1,181 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
namespace WebSharks\CometCache\Traits\Plugin;
|
4 |
+
|
5 |
+
use WebSharks\CometCache\Classes;
|
6 |
+
|
7 |
+
trait AdminBarUtils
|
8 |
+
{
|
9 |
+
/**
|
10 |
+
* Showing admin bar.
|
11 |
+
*
|
12 |
+
* @since 151002 Improving admin bar.
|
13 |
+
*
|
14 |
+
* @param bool $feature Check something specific?
|
15 |
+
*
|
16 |
+
* @return bool True if showing.
|
17 |
+
*/
|
18 |
+
public function adminBarShowing($feature = '')
|
19 |
+
{
|
20 |
+
$feature = trim(mb_strtolower((string) $feature));
|
21 |
+
if (!is_null($showing = &$this->cacheKey('adminBarShowing', $feature))) {
|
22 |
+
return $showing; // Already cached this.
|
23 |
+
}
|
24 |
+
$is_multisite = is_multisite(); // Call this once only.
|
25 |
+
if (($showing = $this->options['enable'] && is_admin_bar_showing())) {
|
26 |
+
switch ($feature) {
|
27 |
+
case 'cache_wipe':
|
28 |
+
$showing = $this->options['cache_clear_admin_bar_enable'] && $is_multisite;
|
29 |
+
break;
|
30 |
+
case 'cache_clear':
|
31 |
+
|
32 |
+
|
33 |
+
default: // Default case handler.
|
34 |
+
$showing = ($this->options['cache_clear_admin_bar_enable'] && $is_multisite)
|
35 |
+
|
36 |
+
|| ($this->options['cache_clear_admin_bar_enable'] && (!$is_multisite || !is_network_admin() || $this->isMenuPage(GLOBAL_NS.'*')));
|
37 |
+
break;
|
38 |
+
}
|
39 |
+
}
|
40 |
+
if ($showing) {
|
41 |
+
$current_user_can_wipe_cache = $is_multisite && current_user_can($this->network_cap);
|
42 |
+
$current_user_can_clear_cache = $this->currentUserCanClearCache();
|
43 |
+
|
44 |
+
switch ($feature) {
|
45 |
+
case 'cache_wipe':
|
46 |
+
$showing = $current_user_can_wipe_cache;
|
47 |
+
break;
|
48 |
+
case 'cache_clear':
|
49 |
+
|
50 |
+
default: // Default case handler.
|
51 |
+
$showing = $current_user_can_wipe_cache
|
52 |
+
|
53 |
+
|| $current_user_can_clear_cache;
|
54 |
+
|
55 |
+
break;
|
56 |
+
}
|
57 |
+
}
|
58 |
+
return $showing;
|
59 |
+
}
|
60 |
+
/**
|
61 |
+
* Filter WordPress admin bar.
|
62 |
+
*
|
63 |
+
* @since 150422 Rewrite.
|
64 |
+
*
|
65 |
+
* @attaches-to `admin_bar_menu` hook.
|
66 |
+
*
|
67 |
+
* @param $wp_admin_bar \WP_Admin_Bar
|
68 |
+
*/
|
69 |
+
public function adminBarMenu(\WP_Admin_Bar &$wp_admin_bar)
|
70 |
+
{
|
71 |
+
if (!$this->adminBarShowing()) {
|
72 |
+
return; // Nothing to do.
|
73 |
+
}
|
74 |
+
if ($this->adminBarShowing('cache_wipe')) {
|
75 |
+
$wp_admin_bar->add_menu(
|
76 |
+
[
|
77 |
+
'parent' => 'top-secondary',
|
78 |
+
'id' => GLOBAL_NS.'-wipe',
|
79 |
+
'title' => __('Wipe', 'comet-cache'),
|
80 |
+
'href' => '#',
|
81 |
+
'meta' => [
|
82 |
+
'title' => __('Wipe Cache (Start Fresh). Clears the cache for all sites in this network at once!', 'comet-cache'),
|
83 |
+
'class' => '-wipe',
|
84 |
+
'tabindex' => -1,
|
85 |
+
],
|
86 |
+
]
|
87 |
+
);
|
88 |
+
}
|
89 |
+
if ($this->adminBarShowing('cache_clear')) {
|
90 |
+
|
91 |
+
$wp_admin_bar->add_menu(
|
92 |
+
[
|
93 |
+
'parent' => 'top-secondary',
|
94 |
+
'id' => GLOBAL_NS.'-clear',
|
95 |
+
'title' => __('Clear Cache', 'comet-cache'),
|
96 |
+
'href' => '#',
|
97 |
+
'meta' => [
|
98 |
+
'title' => is_multisite() && current_user_can($this->network_cap)
|
99 |
+
? __('Clear Cache (Start Fresh). Affects the current site only.', 'comet-cache')
|
100 |
+
: '',
|
101 |
+
'class' => '-clear',
|
102 |
+
'tabindex' => -1,
|
103 |
+
],
|
104 |
+
]
|
105 |
+
);
|
106 |
+
|
107 |
+
}
|
108 |
+
|
109 |
+
}
|
110 |
+
/**
|
111 |
+
* Injects `<meta>` tag w/ JSON-encoded data.
|
112 |
+
*
|
113 |
+
* @since 150422 Rewrite.
|
114 |
+
*
|
115 |
+
* @attaches-to `admin_head` hook.
|
116 |
+
*/
|
117 |
+
public function adminBarMetaTags()
|
118 |
+
{
|
119 |
+
if (!$this->adminBarShowing()) {
|
120 |
+
return; // Nothing to do.
|
121 |
+
}
|
122 |
+
$vars = [
|
123 |
+
'_wpnonce' => wp_create_nonce(),
|
124 |
+
'isMultisite' => is_multisite(),
|
125 |
+
'currentUserHasCap' => current_user_can($this->cap),
|
126 |
+
'currentUserHasNetworkCap' => current_user_can($this->network_cap),
|
127 |
+
'htmlCompressorEnabled' => (boolean) $this->options['htmlc_enable'],
|
128 |
+
'ajaxURL' => site_url('/wp-load.php', is_ssl() ? 'https' : 'http'),
|
129 |
+
'i18n' => [
|
130 |
+
'name' => NAME,
|
131 |
+
'perSymbol' => __('%', 'comet-cache'),
|
132 |
+
'file' => __('file', 'comet-cache'),
|
133 |
+
'files' => __('files', 'comet-cache'),
|
134 |
+
'pageCache' => __('Page Cache', 'comet-cache'),
|
135 |
+
'htmlCompressor' => __('HTML Compressor', 'comet-cache'),
|
136 |
+
'currentTotal' => __('Current Total', 'comet-cache'),
|
137 |
+
'currentSite' => __('Current Site', 'comet-cache'),
|
138 |
+
'xDayHigh' => __('%s Day High', 'comet-cache'),
|
139 |
+
'enterSpecificUrl' => __('Enter a specific URL to clear the cache for that page:', 'comet-cache'),
|
140 |
+
],
|
141 |
+
];
|
142 |
+
echo '<meta property="'.esc_attr(GLOBAL_NS).':admin-bar-vars" content="data-json"'.
|
143 |
+
' data-json="'.esc_attr(json_encode($vars)).'" id="'.esc_attr(GLOBAL_NS).'-admin-bar-vars" />'."\n";
|
144 |
+
}
|
145 |
+
/**
|
146 |
+
* Adds CSS for WordPress admin bar.
|
147 |
+
*
|
148 |
+
* @since 150422 Rewrite.
|
149 |
+
*
|
150 |
+
* @attaches-to `wp_enqueue_scripts` hook.
|
151 |
+
* @attaches-to `admin_enqueue_scripts` hook.
|
152 |
+
*/
|
153 |
+
public function adminBarStyles()
|
154 |
+
{
|
155 |
+
if (!$this->adminBarShowing()) {
|
156 |
+
return; // Nothing to do.
|
157 |
+
}
|
158 |
+
$deps = []; // Plugin dependencies.
|
159 |
+
wp_enqueue_style(GLOBAL_NS.'-admin-bar', $this->url('/src/client-s/css/admin-bar.min.css'), $deps, VERSION, 'all');
|
160 |
+
}
|
161 |
+
/**
|
162 |
+
* Adds JS for WordPress admin bar.
|
163 |
+
*
|
164 |
+
* @since 150422 Rewrite.
|
165 |
+
*
|
166 |
+
* @attaches-to `wp_enqueue_scripts` hook.
|
167 |
+
* @attaches-to `admin_enqueue_scripts` hook.
|
168 |
+
*/
|
169 |
+
public function adminBarScripts()
|
170 |
+
{
|
171 |
+
if (!$this->adminBarShowing()) {
|
172 |
+
return; // Nothing to do.
|
173 |
+
}
|
174 |
+
$deps = ['jquery', 'admin-bar']; // Plugin dependencies.
|
175 |
+
if ($this->adminBarShowing('stats')) {
|
176 |
+
$deps[] = 'chartjs'; // Add ChartJS dependency.
|
177 |
+
wp_enqueue_script('chartjs', set_url_scheme('//cdnjs.cloudflare.com/ajax/libs/Chart.js/1.0.2/Chart.min.js'), [], null, true);
|
178 |
+
}
|
179 |
+
wp_enqueue_script(GLOBAL_NS.'-admin-bar', $this->url('/src/client-s/js/admin-bar.min.js'), $deps, VERSION, true);
|
180 |
+
}
|
181 |
+
}
|
src/includes/traits/Plugin/InstallUtils.php
CHANGED
@@ -47,10 +47,14 @@ trait InstallUtils
|
|
47 |
if (version_compare($prev_version, VERSION, '>=')) {
|
48 |
return; // Nothing to do; up-to-date.
|
49 |
}
|
50 |
-
$this->
|
|
|
|
|
51 |
|
52 |
new Classes\VsUpgrades($prev_version);
|
53 |
|
|
|
|
|
54 |
if ($this->options['enable']) {
|
55 |
$this->addWpCacheToWpConfig();
|
56 |
$this->addWpHtaccess();
|
@@ -126,7 +130,7 @@ trait InstallUtils
|
|
126 |
}
|
127 |
|
128 |
/**
|
129 |
-
* Adds `define('WP_CACHE',
|
130 |
*
|
131 |
* @since 150422 Rewrite.
|
132 |
*
|
@@ -150,16 +154,16 @@ trait InstallUtils
|
|
150 |
if (!($wp_config_file_contents_no_whitespace = php_strip_whitespace($wp_config_file))) {
|
151 |
return ''; // Failure; file empty
|
152 |
}
|
153 |
-
if (preg_match('/\bdefine\s*\(\s*([\'"])WP_CACHE\\1\s*,\s*(?:\-?[1-9][0-9\.]*|
|
154 |
return $wp_config_file_contents; // It's already in there; no need to modify this file.
|
155 |
}
|
156 |
if (!($wp_config_file_contents = $this->removeWpCacheFromWpConfig())) {
|
157 |
return ''; // Unable to remove previous value.
|
158 |
}
|
159 |
-
if (!($wp_config_file_contents = preg_replace('/^\s*(\<\?php|\<\?)\s+/ui', '${1}'."\n"."define('WP_CACHE',
|
160 |
return ''; // Failure; something went terribly wrong here.
|
161 |
}
|
162 |
-
if (mb_strpos($wp_config_file_contents, "define('WP_CACHE',
|
163 |
return ''; // Failure; unable to add; unexpected PHP code.
|
164 |
}
|
165 |
if (defined('DISALLOW_FILE_MODS') && DISALLOW_FILE_MODS) {
|
@@ -175,7 +179,7 @@ trait InstallUtils
|
|
175 |
}
|
176 |
|
177 |
/**
|
178 |
-
* Removes `define('WP_CACHE',
|
179 |
*
|
180 |
* @since 150422 Rewrite.
|
181 |
*
|
@@ -252,7 +256,7 @@ trait InstallUtils
|
|
252 |
// Fixes zero-byte advanced-cache.php bug related to migrating from ZenCache
|
253 |
// See: <https://github.com/websharks/zencache/issues/432>
|
254 |
|
255 |
-
// Also fixes a missing `define('WP_CACHE',
|
256 |
// See <https://github.com/websharks/zencache/issues/450>
|
257 |
|
258 |
if (!is_file($advanced_cache_check_file) || !is_file($advanced_cache_file) || filesize($advanced_cache_file) === 0) {
|
@@ -278,7 +282,7 @@ trait InstallUtils
|
|
278 |
$cache_dir = $this->cacheDir();
|
279 |
$advanced_cache_file = WP_CONTENT_DIR.'/advanced-cache.php';
|
280 |
$advanced_cache_check_file = $cache_dir.'/'.mb_strtolower(SHORT_NAME).'-advanced-cache';
|
281 |
-
$advanced_cache_template = dirname(dirname(__DIR__)).'/templates/advanced-cache.
|
282 |
|
283 |
if (is_file($advanced_cache_file) && !is_writable($advanced_cache_file)) {
|
284 |
return false; // Not possible to create.
|
@@ -352,7 +356,8 @@ trait InstallUtils
|
|
352 |
}
|
353 |
$cache_lock = $this->cacheLock(); // Lock cache.
|
354 |
|
355 |
-
|
|
|
356 |
mkdir($cache_dir, 0775, true);
|
357 |
}
|
358 |
if (is_writable($cache_dir) && !is_file($cache_dir.'/.htaccess')) {
|
@@ -503,7 +508,8 @@ trait InstallUtils
|
|
503 |
|
504 |
$cache_lock = $this->cacheLock();
|
505 |
|
506 |
-
|
|
|
507 |
mkdir($cache_dir, 0775, true);
|
508 |
}
|
509 |
if (is_writable($cache_dir) && !is_file($cache_dir.'/.htaccess')) {
|
47 |
if (version_compare($prev_version, VERSION, '>=')) {
|
48 |
return; // Nothing to do; up-to-date.
|
49 |
}
|
50 |
+
$this->options = $this->getOptions(false, true); // Don't discard options not present in $this->default_options, and DO force-pull options directly from get_site_option()
|
51 |
+
|
52 |
+
$this->updateOptions(['version' => VERSION], false); // Retain all options in database for VS Upgrade routine
|
53 |
|
54 |
new Classes\VsUpgrades($prev_version);
|
55 |
|
56 |
+
$this->updateOptions(['version' => VERSION], true); // Discard options not present in $this->default_options
|
57 |
+
|
58 |
if ($this->options['enable']) {
|
59 |
$this->addWpCacheToWpConfig();
|
60 |
$this->addWpHtaccess();
|
130 |
}
|
131 |
|
132 |
/**
|
133 |
+
* Adds `define( 'WP_CACHE', true );` to the `/wp-config.php` file.
|
134 |
*
|
135 |
* @since 150422 Rewrite.
|
136 |
*
|
154 |
if (!($wp_config_file_contents_no_whitespace = php_strip_whitespace($wp_config_file))) {
|
155 |
return ''; // Failure; file empty
|
156 |
}
|
157 |
+
if (preg_match('/\bdefine\s*\(\s*([\'"])WP_CACHE\\1\s*,\s*(?:\-?[1-9][0-9\.]*|true|([\'"])(?:[^0\'"]|[^\'"]{2,})\\2)\s*\)\s*;/ui', $wp_config_file_contents_no_whitespace)) {
|
158 |
return $wp_config_file_contents; // It's already in there; no need to modify this file.
|
159 |
}
|
160 |
if (!($wp_config_file_contents = $this->removeWpCacheFromWpConfig())) {
|
161 |
return ''; // Unable to remove previous value.
|
162 |
}
|
163 |
+
if (!($wp_config_file_contents = preg_replace('/^\s*(\<\?php|\<\?)\s+/ui', '${1}'."\n"."define( 'WP_CACHE', true );"."\n", $wp_config_file_contents, 1))) {
|
164 |
return ''; // Failure; something went terribly wrong here.
|
165 |
}
|
166 |
+
if (mb_strpos($wp_config_file_contents, "define( 'WP_CACHE', true );") === false) {
|
167 |
return ''; // Failure; unable to add; unexpected PHP code.
|
168 |
}
|
169 |
if (defined('DISALLOW_FILE_MODS') && DISALLOW_FILE_MODS) {
|
179 |
}
|
180 |
|
181 |
/**
|
182 |
+
* Removes `define( 'WP_CACHE', true );` from the `/wp-config.php` file.
|
183 |
*
|
184 |
* @since 150422 Rewrite.
|
185 |
*
|
256 |
// Fixes zero-byte advanced-cache.php bug related to migrating from ZenCache
|
257 |
// See: <https://github.com/websharks/zencache/issues/432>
|
258 |
|
259 |
+
// Also fixes a missing `define( 'WP_CACHE', true )` bug related to migrating from ZenCache
|
260 |
// See <https://github.com/websharks/zencache/issues/450>
|
261 |
|
262 |
if (!is_file($advanced_cache_check_file) || !is_file($advanced_cache_file) || filesize($advanced_cache_file) === 0) {
|
282 |
$cache_dir = $this->cacheDir();
|
283 |
$advanced_cache_file = WP_CONTENT_DIR.'/advanced-cache.php';
|
284 |
$advanced_cache_check_file = $cache_dir.'/'.mb_strtolower(SHORT_NAME).'-advanced-cache';
|
285 |
+
$advanced_cache_template = dirname(dirname(__DIR__)).'/templates/advanced-cache.x-php';
|
286 |
|
287 |
if (is_file($advanced_cache_file) && !is_writable($advanced_cache_file)) {
|
288 |
return false; // Not possible to create.
|
356 |
}
|
357 |
$cache_lock = $this->cacheLock(); // Lock cache.
|
358 |
|
359 |
+
clearstatcache();
|
360 |
+
if (!file_exists($cache_dir)) {
|
361 |
mkdir($cache_dir, 0775, true);
|
362 |
}
|
363 |
if (is_writable($cache_dir) && !is_file($cache_dir.'/.htaccess')) {
|
508 |
|
509 |
$cache_lock = $this->cacheLock();
|
510 |
|
511 |
+
clearstatcache();
|
512 |
+
if (!file_exists($cache_dir)) {
|
513 |
mkdir($cache_dir, 0775, true);
|
514 |
}
|
515 |
if (is_writable($cache_dir) && !is_file($cache_dir.'/.htaccess')) {
|
src/includes/traits/Plugin/MenuPageUtils.php
CHANGED
@@ -84,8 +84,6 @@ trait MenuPageUtils
|
|
84 |
add_submenu_page(GLOBAL_NS, __('Plugin Options', 'comet-cache'), __('Plugin Options', 'comet-cache'), $this->network_cap, GLOBAL_NS, [$this, 'menuPageOptions']);
|
85 |
|
86 |
|
87 |
-
|
88 |
-
|
89 |
}
|
90 |
|
91 |
/**
|
@@ -107,8 +105,6 @@ trait MenuPageUtils
|
|
107 |
add_submenu_page(GLOBAL_NS, __('Plugin Options', 'comet-cache'), __('Plugin Options', 'comet-cache'), $this->cap, GLOBAL_NS, [$this, 'menuPageOptions']);
|
108 |
|
109 |
|
110 |
-
|
111 |
-
|
112 |
}
|
113 |
|
114 |
/**
|
@@ -177,14 +173,12 @@ trait MenuPageUtils
|
|
177 |
|
178 |
|
179 |
|
180 |
-
|
181 |
-
|
182 |
/**
|
183 |
* WordPress admin icon color schemes.
|
184 |
*
|
185 |
* @since 150422 Rewrite.
|
186 |
*
|
187 |
-
* @
|
188 |
*
|
189 |
* @note These must be hard-coded, because they don't become available
|
190 |
* in core until `admin_init`; i.e., too late for `admin_menu`.
|
84 |
add_submenu_page(GLOBAL_NS, __('Plugin Options', 'comet-cache'), __('Plugin Options', 'comet-cache'), $this->network_cap, GLOBAL_NS, [$this, 'menuPageOptions']);
|
85 |
|
86 |
|
|
|
|
|
87 |
}
|
88 |
|
89 |
/**
|
105 |
add_submenu_page(GLOBAL_NS, __('Plugin Options', 'comet-cache'), __('Plugin Options', 'comet-cache'), $this->cap, GLOBAL_NS, [$this, 'menuPageOptions']);
|
106 |
|
107 |
|
|
|
|
|
108 |
}
|
109 |
|
110 |
/**
|
173 |
|
174 |
|
175 |
|
|
|
|
|
176 |
/**
|
177 |
* WordPress admin icon color schemes.
|
178 |
*
|
179 |
* @since 150422 Rewrite.
|
180 |
*
|
181 |
+
* @var array WP admin icon colors.
|
182 |
*
|
183 |
* @note These must be hard-coded, because they don't become available
|
184 |
* in core until `admin_init`; i.e., too late for `admin_menu`.
|
src/includes/traits/Plugin/OptionUtils.php
CHANGED
@@ -10,11 +10,16 @@ trait OptionUtils
|
|
10 |
*
|
11 |
* @since 151002 Improving multisite compat.
|
12 |
*
|
|
|
|
|
|
|
13 |
* @return array Plugin options.
|
|
|
|
|
14 |
*/
|
15 |
-
public function getOptions()
|
16 |
{
|
17 |
-
if (!($options = $this->options)) { //
|
18 |
if (!is_array($options = get_site_option(GLOBAL_NS.'_options'))) {
|
19 |
$options = []; // Force array.
|
20 |
}
|
@@ -27,7 +32,7 @@ trait OptionUtils
|
|
27 |
}
|
28 |
$this->options = array_merge($this->default_options, $options);
|
29 |
$this->options = $this->applyWpFilters(GLOBAL_NS.'_options', $this->options);
|
30 |
-
$this->options = array_intersect_key($this->options, $this->default_options);
|
31 |
|
32 |
foreach ($this->options as $_key => &$_value) {
|
33 |
$_value = trim((string) $_value); // Force strings.
|
@@ -47,10 +52,13 @@ trait OptionUtils
|
|
47 |
* @since 151002 Improving multisite compat.
|
48 |
*
|
49 |
* @param array $options One or more new options.
|
|
|
50 |
*
|
51 |
* @return array Plugin options after update.
|
|
|
|
|
52 |
*/
|
53 |
-
public function updateOptions(array $options)
|
54 |
{
|
55 |
if (!IS_PRO) { // Do not save Pro option keys.
|
56 |
$options = array_diff_key($options, $this->pro_only_option_keys);
|
@@ -59,10 +67,10 @@ trait OptionUtils
|
|
59 |
$this->tryErasingAllFilesDirsIn($this->wpContentBaseDirTo(''));
|
60 |
}
|
61 |
$this->options = array_merge($this->default_options, $this->options, $options);
|
62 |
-
$this->options = array_intersect_key($this->options, $this->default_options);
|
63 |
update_site_option(GLOBAL_NS.'_options', $this->options);
|
64 |
|
65 |
-
return $this->getOptions();
|
66 |
}
|
67 |
|
68 |
/**
|
10 |
*
|
11 |
* @since 151002 Improving multisite compat.
|
12 |
*
|
13 |
+
* @param bool $intersect Discard options not present in $this->default_options
|
14 |
+
* @param bool $refresh Force-pull options directly from get_site_option()
|
15 |
+
*
|
16 |
* @return array Plugin options.
|
17 |
+
*
|
18 |
+
* @note $intersect should be `false` when this method is called via a VS upgrade routine or during inital startup on when upgrading. See https://git.io/viGIK
|
19 |
*/
|
20 |
+
public function getOptions($intersect = true, $refresh = false)
|
21 |
{
|
22 |
+
if (!($options = $this->options) || $refresh) { // If not defined yet, or if we're forcing a refresh via get_site_option()
|
23 |
if (!is_array($options = get_site_option(GLOBAL_NS.'_options'))) {
|
24 |
$options = []; // Force array.
|
25 |
}
|
32 |
}
|
33 |
$this->options = array_merge($this->default_options, $options);
|
34 |
$this->options = $this->applyWpFilters(GLOBAL_NS.'_options', $this->options);
|
35 |
+
$this->options = $intersect ? array_intersect_key($this->options, $this->default_options) : $this->options;
|
36 |
|
37 |
foreach ($this->options as $_key => &$_value) {
|
38 |
$_value = trim((string) $_value); // Force strings.
|
52 |
* @since 151002 Improving multisite compat.
|
53 |
*
|
54 |
* @param array $options One or more new options.
|
55 |
+
* @param bool $intersect Discard options not present in $this->default_options
|
56 |
*
|
57 |
* @return array Plugin options after update.
|
58 |
+
*
|
59 |
+
* @note $intersect should be `false` when this method is called via a VS upgrade routine. See https://git.io/viGIK
|
60 |
*/
|
61 |
+
public function updateOptions(array $options, $intersect = true)
|
62 |
{
|
63 |
if (!IS_PRO) { // Do not save Pro option keys.
|
64 |
$options = array_diff_key($options, $this->pro_only_option_keys);
|
67 |
$this->tryErasingAllFilesDirsIn($this->wpContentBaseDirTo(''));
|
68 |
}
|
69 |
$this->options = array_merge($this->default_options, $this->options, $options);
|
70 |
+
$this->options = $intersect ? array_intersect_key($this->options, $this->default_options) : $this->options;
|
71 |
update_site_option(GLOBAL_NS.'_options', $this->options);
|
72 |
|
73 |
+
return $this->getOptions($intersect);
|
74 |
}
|
75 |
|
76 |
/**
|
src/includes/traits/Plugin/UpdateUtils.php
CHANGED
@@ -9,6 +9,7 @@ trait UpdateUtils
|
|
9 |
* Checks for a new lite release.
|
10 |
*
|
11 |
* @since 151220 Show version number in plugin options.
|
|
|
12 |
*
|
13 |
* @attaches-to `admin_init` hook.
|
14 |
*/
|
@@ -16,18 +17,12 @@ trait UpdateUtils
|
|
16 |
{
|
17 |
if (IS_PRO) {
|
18 |
return; // Not applicable.
|
19 |
-
}
|
20 |
-
if (!$this->options['lite_update_check']) {
|
21 |
-
return; // Nothing to do.
|
22 |
-
}
|
23 |
-
if (!current_user_can($this->update_cap)) {
|
24 |
return; // Nothing to do.
|
25 |
-
}
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
if ($this->options['last_lite_update_check'] >= strtotime('-1 hour')) {
|
30 |
-
return; // No reason to keep checking on this.
|
31 |
}
|
32 |
$this->updateOptions(['last_lite_update_check' => time()]);
|
33 |
|
@@ -40,12 +35,6 @@ trait UpdateUtils
|
|
40 |
if (is_object($product_api_response) && !empty($product_api_response->lite_version)) {
|
41 |
$this->updateOptions(['latest_lite_version' => $product_api_response->lite_version]);
|
42 |
}
|
43 |
-
// Disabling the notice for now. We only run this check to collect the latest version number.
|
44 |
-
#if ($this->options['latest_lite_version'] && version_compare(VERSION, $this->options['latest_lite_version'], '<')) {
|
45 |
-
# $this->dismissMainNotice('new-lite-version-available'); // Dismiss any existing notices like this.
|
46 |
-
# $lite_updater_page = network_admin_url('/plugins.php'); // In a network this points to the master plugins list.
|
47 |
-
# $this->enqueueMainNotice(sprintf(__('<strong>%1$s:</strong> a new version is now available. Please <a href="%2$s">upgrade to v%3$s</a>.', 'comet-cache'), esc_html(NAME), esc_attr($lite_updater_page), esc_html($this->options['latest_lite_version'])), array('persistent_key' => 'new-lite-version-available'));
|
48 |
-
#}
|
49 |
}
|
50 |
|
51 |
|
9 |
* Checks for a new lite release.
|
10 |
*
|
11 |
* @since 151220 Show version number in plugin options.
|
12 |
+
* @since 160917 Don't check current user.
|
13 |
*
|
14 |
* @attaches-to `admin_init` hook.
|
15 |
*/
|
17 |
{
|
18 |
if (IS_PRO) {
|
19 |
return; // Not applicable.
|
20 |
+
} elseif (!$this->options['lite_update_check']) {
|
|
|
|
|
|
|
|
|
21 |
return; // Nothing to do.
|
22 |
+
} elseif ($this->options['last_lite_update_check'] >= strtotime('-1 hour')) {
|
23 |
+
if (empty($_REQUEST['force-check'])) {
|
24 |
+
return; // Nothing to do.
|
25 |
+
}
|
|
|
|
|
26 |
}
|
27 |
$this->updateOptions(['last_lite_update_check' => time()]);
|
28 |
|
35 |
if (is_object($product_api_response) && !empty($product_api_response->lite_version)) {
|
36 |
$this->updateOptions(['latest_lite_version' => $product_api_response->lite_version]);
|
37 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
38 |
}
|
39 |
|
40 |
|
src/includes/traits/Plugin/WcpSettingUtils.php
CHANGED
@@ -15,15 +15,20 @@ trait WcpSettingUtils
|
|
15 |
*/
|
16 |
public function autoClearCacheOnSettingChanges()
|
17 |
{
|
18 |
-
$counter
|
19 |
-
$pagenow
|
20 |
-
$
|
|
|
21 |
|
22 |
-
if (!is_null($done = &$this->cacheKey('autoClearCacheOnSettingChanges', [$pagenow, $settings_updated]))) {
|
23 |
return $counter; // Already did this.
|
24 |
}
|
25 |
$done = true; // Flag as having been done.
|
26 |
|
|
|
|
|
|
|
|
|
27 |
if ($pagenow === 'options-general.php' && $settings_updated) {
|
28 |
$this->addWpHtaccess(); // Update .htaccess if applicable
|
29 |
$counter += $this->autoClearCache();
|
15 |
*/
|
16 |
public function autoClearCacheOnSettingChanges()
|
17 |
{
|
18 |
+
$counter = 0; // Initialize.
|
19 |
+
$pagenow = !empty($GLOBALS['pagenow']) ? $GLOBALS['pagenow'] : '';
|
20 |
+
$other_option_page = !empty($_REQUEST['page']);
|
21 |
+
$settings_updated = !empty($_REQUEST['settings-updated']);
|
22 |
|
23 |
+
if (!is_null($done = &$this->cacheKey('autoClearCacheOnSettingChanges', [$pagenow, $other_option_page, $settings_updated]))) {
|
24 |
return $counter; // Already did this.
|
25 |
}
|
26 |
$done = true; // Flag as having been done.
|
27 |
|
28 |
+
if ($pagenow === 'options-general.php' && $other_option_page) {
|
29 |
+
return $counter; // Nothing to do. See: https://git.io/viYqE
|
30 |
+
}
|
31 |
+
|
32 |
if ($pagenow === 'options-general.php' && $settings_updated) {
|
33 |
$this->addWpHtaccess(); // Update .htaccess if applicable
|
34 |
$counter += $this->autoClearCache();
|
src/includes/traits/Plugin/WcpUpdaterUtils.php
CHANGED
@@ -46,7 +46,9 @@ trait WcpUpdaterUtils
|
|
46 |
}
|
47 |
}
|
48 |
unset($_plugin); // Housekeeping.
|
49 |
-
} elseif ($single_plugin_update && (
|
|
|
|
|
50 |
$upgrading_active_plugin = true;
|
51 |
}
|
52 |
if ($upgrading_active_plugin) {
|
46 |
}
|
47 |
}
|
48 |
unset($_plugin); // Housekeeping.
|
49 |
+
} elseif ($single_plugin_update && (is_plugin_active($data['plugin'])
|
50 |
+
|| !empty($upgrader_instance->skin->upgrader->skin->plugin_active)
|
51 |
+
|| !empty($upgrader_instance->skin->upgrader->skin->plugin_network_active))) {
|
52 |
$upgrading_active_plugin = true;
|
53 |
}
|
54 |
if ($upgrading_active_plugin) {
|
src/vendor/autoload.php
CHANGED
@@ -4,4 +4,4 @@
|
|
4 |
|
5 |
require_once __DIR__ . '/composer' . '/autoload_real.php';
|
6 |
|
7 |
-
return
|
4 |
|
5 |
require_once __DIR__ . '/composer' . '/autoload_real.php';
|
6 |
|
7 |
+
return ComposerAutoloaderInit62f8f3ca78045447be6889b49666f4b3::getLoader();
|
src/vendor/composer/autoload_classmap.php
CHANGED
@@ -28,6 +28,7 @@ return array(
|
|
28 |
'WebSharks\\CometCache\\Traits\\Ac\\PostloadUtils' => $baseDir . '/src/includes/traits/Ac/PostloadUtils.php',
|
29 |
'WebSharks\\CometCache\\Traits\\Ac\\ShutdownUtils' => $baseDir . '/src/includes/traits/Ac/ShutdownUtils.php',
|
30 |
'WebSharks\\CometCache\\Traits\\Plugin\\ActionUtils' => $baseDir . '/src/includes/traits/Plugin/ActionUtils.php',
|
|
|
31 |
'WebSharks\\CometCache\\Traits\\Plugin\\BbPressUtils' => $baseDir . '/src/includes/traits/Plugin/BbPressUtils.php',
|
32 |
'WebSharks\\CometCache\\Traits\\Plugin\\CleanupUtils' => $baseDir . '/src/includes/traits/Plugin/CleanupUtils.php',
|
33 |
'WebSharks\\CometCache\\Traits\\Plugin\\CondUtils' => $baseDir . '/src/includes/traits/Plugin/CondUtils.php',
|
28 |
'WebSharks\\CometCache\\Traits\\Ac\\PostloadUtils' => $baseDir . '/src/includes/traits/Ac/PostloadUtils.php',
|
29 |
'WebSharks\\CometCache\\Traits\\Ac\\ShutdownUtils' => $baseDir . '/src/includes/traits/Ac/ShutdownUtils.php',
|
30 |
'WebSharks\\CometCache\\Traits\\Plugin\\ActionUtils' => $baseDir . '/src/includes/traits/Plugin/ActionUtils.php',
|
31 |
+
'WebSharks\\CometCache\\Traits\\Plugin\\AdminBarUtils' => $baseDir . '/src/includes/traits/Plugin/AdminBarUtils.php',
|
32 |
'WebSharks\\CometCache\\Traits\\Plugin\\BbPressUtils' => $baseDir . '/src/includes/traits/Plugin/BbPressUtils.php',
|
33 |
'WebSharks\\CometCache\\Traits\\Plugin\\CleanupUtils' => $baseDir . '/src/includes/traits/Plugin/CleanupUtils.php',
|
34 |
'WebSharks\\CometCache\\Traits\\Plugin\\CondUtils' => $baseDir . '/src/includes/traits/Plugin/CondUtils.php',
|
src/vendor/composer/autoload_real.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
|
3 |
// autoload_real.php @generated by Composer
|
4 |
|
5 |
-
class
|
6 |
{
|
7 |
private static $loader;
|
8 |
|
@@ -19,9 +19,9 @@ class ComposerAutoloaderInit0ecf493fec48f48e608cdb485c29bf1b
|
|
19 |
return self::$loader;
|
20 |
}
|
21 |
|
22 |
-
spl_autoload_register(array('
|
23 |
self::$loader = $loader = new \Composer\Autoload\ClassLoader();
|
24 |
-
spl_autoload_unregister(array('
|
25 |
|
26 |
$map = require __DIR__ . '/autoload_namespaces.php';
|
27 |
foreach ($map as $namespace => $path) {
|
2 |
|
3 |
// autoload_real.php @generated by Composer
|
4 |
|
5 |
+
class ComposerAutoloaderInit62f8f3ca78045447be6889b49666f4b3
|
6 |
{
|
7 |
private static $loader;
|
8 |
|
19 |
return self::$loader;
|
20 |
}
|
21 |
|
22 |
+
spl_autoload_register(array('ComposerAutoloaderInit62f8f3ca78045447be6889b49666f4b3', 'loadClassLoader'), true, true);
|
23 |
self::$loader = $loader = new \Composer\Autoload\ClassLoader();
|
24 |
+
spl_autoload_unregister(array('ComposerAutoloaderInit62f8f3ca78045447be6889b49666f4b3', 'loadClassLoader'));
|
25 |
|
26 |
$map = require __DIR__ . '/autoload_namespaces.php';
|
27 |
foreach ($map as $namespace => $path) {
|
src/vendor/composer/installed.json
CHANGED
@@ -227,23 +227,23 @@
|
|
227 |
},
|
228 |
{
|
229 |
"name": "websharks/wp-php-rv",
|
230 |
-
"version": "
|
231 |
-
"version_normalized": "
|
232 |
"source": {
|
233 |
"type": "git",
|
234 |
"url": "https://github.com/websharks/wp-php-rv.git",
|
235 |
-
"reference": "
|
236 |
},
|
237 |
"dist": {
|
238 |
"type": "zip",
|
239 |
-
"url": "https://api.github.com/repos/websharks/wp-php-rv/zipball/
|
240 |
-
"reference": "
|
241 |
"shasum": ""
|
242 |
},
|
243 |
"require": {
|
244 |
"php": ">=5.2"
|
245 |
},
|
246 |
-
"time": "2016-
|
247 |
"type": "library",
|
248 |
"installation-source": "dist",
|
249 |
"notification-url": "https://packagist.org/downloads/",
|
@@ -251,20 +251,20 @@
|
|
251 |
"GPL-3.0+"
|
252 |
],
|
253 |
"authors": [
|
254 |
-
{
|
255 |
-
"name": "websharks",
|
256 |
-
"homepage": "http://websharks-inc.com/",
|
257 |
-
"role": "company"
|
258 |
-
},
|
259 |
{
|
260 |
"name": "jaswsinc",
|
261 |
-
"homepage": "
|
262 |
"role": "developer"
|
263 |
},
|
264 |
{
|
265 |
"name": "raamdev",
|
266 |
-
"homepage": "http://raam.org
|
267 |
"role": "developer"
|
|
|
|
|
|
|
|
|
|
|
268 |
}
|
269 |
],
|
270 |
"description": "Stub for WordPress themes/plugins that require PHP vX.x+.",
|
@@ -272,7 +272,8 @@
|
|
272 |
"keywords": [
|
273 |
"php",
|
274 |
"websharks",
|
275 |
-
"wordpress"
|
|
|
276 |
]
|
277 |
}
|
278 |
]
|
227 |
},
|
228 |
{
|
229 |
"name": "websharks/wp-php-rv",
|
230 |
+
"version": "160824.6416",
|
231 |
+
"version_normalized": "160824.6416",
|
232 |
"source": {
|
233 |
"type": "git",
|
234 |
"url": "https://github.com/websharks/wp-php-rv.git",
|
235 |
+
"reference": "d889d4ac090d674153a8de1ec2ae927527d66d35"
|
236 |
},
|
237 |
"dist": {
|
238 |
"type": "zip",
|
239 |
+
"url": "https://api.github.com/repos/websharks/wp-php-rv/zipball/d889d4ac090d674153a8de1ec2ae927527d66d35",
|
240 |
+
"reference": "d889d4ac090d674153a8de1ec2ae927527d66d35",
|
241 |
"shasum": ""
|
242 |
},
|
243 |
"require": {
|
244 |
"php": ">=5.2"
|
245 |
},
|
246 |
+
"time": "2016-08-24 01:47:28",
|
247 |
"type": "library",
|
248 |
"installation-source": "dist",
|
249 |
"notification-url": "https://packagist.org/downloads/",
|
251 |
"GPL-3.0+"
|
252 |
],
|
253 |
"authors": [
|
|
|
|
|
|
|
|
|
|
|
254 |
{
|
255 |
"name": "jaswsinc",
|
256 |
+
"homepage": "https://jaswsinc.com",
|
257 |
"role": "developer"
|
258 |
},
|
259 |
{
|
260 |
"name": "raamdev",
|
261 |
+
"homepage": "http://raam.org",
|
262 |
"role": "developer"
|
263 |
+
},
|
264 |
+
{
|
265 |
+
"name": "wpsharks",
|
266 |
+
"homepage": "https://wpsharks.com",
|
267 |
+
"role": "company"
|
268 |
}
|
269 |
],
|
270 |
"description": "Stub for WordPress themes/plugins that require PHP vX.x+.",
|
272 |
"keywords": [
|
273 |
"php",
|
274 |
"websharks",
|
275 |
+
"wordpress",
|
276 |
+
"wpsharks"
|
277 |
]
|
278 |
}
|
279 |
]
|
src/vendor/websharks/sharkicons/README.md
DELETED
@@ -1,154 +0,0 @@
|
|
1 |
-
## WebSharks™ Icon Font (Sharkicons)
|
2 |
-
|
3 |
-
Font containing WebSharks logos/icons + many others; including FontAwesome! See: [**DEMO**](http://websharks.github.io/sharkicons/demo.html)
|
4 |
-
|
5 |
-
_Contains over 750 icons. Total file size: 212kb (compare to stand-alone FontAwesome @ 136kb)._
|
6 |
-
|
7 |
-
[![](https://img.shields.io/github/license/websharks/sharkicons.svg)](https://github.com/websharks/sharkicons/blob/HEAD/LICENSE.txt)
|
8 |
-
[![](https://img.shields.io/badge/made-w%2F_100%25_pure_awesome_sauce-AB815F.svg?label=made)](http://websharks-inc.com/)
|
9 |
-
[![](https://img.shields.io/badge/by-WebSharks_Inc.-656598.svg?label=by)](http://www.websharks-inc.com/team/)
|
10 |
-
[![](https://img.shields.io/github/release/websharks/sharkicons.svg?label=latest)](https://github.com/websharks/sharkicons/releases)
|
11 |
-
[![](https://img.shields.io/packagist/v/websharks/sharkicons.svg?label=packagist)](https://packagist.org/packages/websharks/sharkicons)
|
12 |
-
[![](https://img.shields.io/github/issues/websharks/sharkicons.svg?label=issues)](https://github.com/websharks/sharkicons/issues)
|
13 |
-
[![](https://img.shields.io/github/forks/websharks/sharkicons.svg?label=forks)](https://github.com/websharks/sharkicons/network)
|
14 |
-
[![](https://img.shields.io/github/stars/websharks/sharkicons.svg?label=stars)](https://github.com/websharks/sharkicons/stargazers)
|
15 |
-
[![](https://img.shields.io/github/downloads/websharks/sharkicons/latest/total.svg?label=downloads)](https://github.com/websharks/sharkicons/releases)
|
16 |
-
[![](https://img.shields.io/packagist/dt/websharks/sharkicons.svg?label=packagist)](https://packagist.org/packages/websharks/sharkicons)
|
17 |
-
|
18 |
-
---
|
19 |
-
|
20 |
-
![](assets/screenshot.png)
|
21 |
-
|
22 |
-
---
|
23 |
-
|
24 |
-
## Using Icons in HTML Markup
|
25 |
-
|
26 |
-
```html
|
27 |
-
<link rel="stylesheet" type="text/css" href="/path/to/sharkicons/src/long-classes.min.css" />
|
28 |
-
```
|
29 |
-
|
30 |
-
```html
|
31 |
-
<i class="sharkicon sharkicon-broom"></i>
|
32 |
-
```
|
33 |
-
|
34 |
-
---
|
35 |
-
|
36 |
-
## Short Classes (`si-` instead of `sharkicon-`)
|
37 |
-
|
38 |
-
```html
|
39 |
-
<link rel="stylesheet" type="text/css" href="/path/to/sharkicons/src/short-classes.min.css" />
|
40 |
-
```
|
41 |
-
|
42 |
-
```html
|
43 |
-
<i class="si si-broom"></i>
|
44 |
-
```
|
45 |
-
|
46 |
-
---
|
47 |
-
|
48 |
-
## Including Classes via SCSS
|
49 |
-
|
50 |
-
_**Note:** Bourbon is a required dependency. See: <http://bourbon.io/> for details._
|
51 |
-
|
52 |
-
```scss
|
53 |
-
@import '/path/to/bourbon';
|
54 |
-
@import '/path/to/sharkicons/src/sharkicons';
|
55 |
-
@include sharkicons-font('/path/to/sharkicons/src');
|
56 |
-
@include sharkicon-short-classes;
|
57 |
-
```
|
58 |
-
|
59 |
-
---
|
60 |
-
|
61 |
-
## Custom Classes via SCSS (`prefix` instead of `si`)
|
62 |
-
|
63 |
-
```scss
|
64 |
-
@import '/path/to/bourbon';
|
65 |
-
@import '/path/to/sharkicons/src/sharkicons';
|
66 |
-
@include sharkicons-font('/path/to/sharkicons/src');
|
67 |
-
@include sharkicon-custom-classes(prefix);
|
68 |
-
```
|
69 |
-
|
70 |
-
---
|
71 |
-
|
72 |
-
## Scoping Classes via SCSS
|
73 |
-
|
74 |
-
```scss
|
75 |
-
@import '/path/to/bourbon';
|
76 |
-
@import '/path/to/sharkicons/src/sharkicons';
|
77 |
-
@include sharkicons-font('/path/to/sharkicons/src');
|
78 |
-
|
79 |
-
.my-product {
|
80 |
-
@include sharkicon-short-classes;
|
81 |
-
}
|
82 |
-
```
|
83 |
-
|
84 |
-
---
|
85 |
-
|
86 |
-
## Creating an Icon via SCSS
|
87 |
-
|
88 |
-
_Note: you can do this without including the `sharkicon-[long|short]-classes` if you like._
|
89 |
-
|
90 |
-
```scss
|
91 |
-
@import '/path/to/bourbon';
|
92 |
-
@import '/path/to/sharkicons/src/sharkicons';
|
93 |
-
@include sharkicons-font('/path/to/sharkicons/src');
|
94 |
-
// @include sharkicon-short-classes;
|
95 |
-
|
96 |
-
.my-product .my-icon {
|
97 |
-
@include sharkicon(broom);
|
98 |
-
}
|
99 |
-
```
|
100 |
-
|
101 |
-
Equivalent to:
|
102 |
-
|
103 |
-
```css
|
104 |
-
.my-product .my-icon::before {
|
105 |
-
content: '\e000';
|
106 |
-
font: normal normal normal 14px/1 sharkicons;
|
107 |
-
text-rendering: optimizeLegibility;
|
108 |
-
-webkit-font-smoothing: antialiased;
|
109 |
-
font-smoothing: antialiased;
|
110 |
-
display: inline-block;
|
111 |
-
font-size: inherit;
|
112 |
-
text-decoration: inherit;
|
113 |
-
text-transform: none;
|
114 |
-
}
|
115 |
-
```
|
116 |
-
|
117 |
-
Alternatively, you can pass a second argument to `sharkicon()` to set the before/after specification. The default value is `before`. You might want to change it to `after` in some special case.
|
118 |
-
|
119 |
-
```scss
|
120 |
-
@import '/path/to/bourbon';
|
121 |
-
@import '/path/to/sharkicons/src/sharkicons';
|
122 |
-
@include sharkicons-font('/path/to/sharkicons/src');
|
123 |
-
// @include sharkicon-short-classes;
|
124 |
-
|
125 |
-
.my-product .my-icon {
|
126 |
-
@include sharkicon(broom, after);
|
127 |
-
}
|
128 |
-
```
|
129 |
-
|
130 |
-
Equivalent to:
|
131 |
-
|
132 |
-
```css
|
133 |
-
.my-product .my-icon::after {
|
134 |
-
content: '\e000';
|
135 |
-
font: normal normal normal 14px/1 sharkicons;
|
136 |
-
text-rendering: optimizeLegibility;
|
137 |
-
-webkit-font-smoothing: antialiased;
|
138 |
-
font-smoothing: antialiased;
|
139 |
-
display: inline-block;
|
140 |
-
font-size: inherit;
|
141 |
-
text-decoration: inherit;
|
142 |
-
text-transform: none;
|
143 |
-
}
|
144 |
-
```
|
145 |
-
|
146 |
-
---
|
147 |
-
|
148 |
-
## Mapping An Icon Char via SCSS
|
149 |
-
|
150 |
-
```scss
|
151 |
-
.my-product .my-icon:hover::after {
|
152 |
-
content: map-get($sharkicons, broom);
|
153 |
-
}
|
154 |
-
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/vendor/websharks/wp-php-rv/CHANGELOG.md
CHANGED
@@ -1,3 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
## v160504
|
2 |
|
3 |
- Adding support for required bits via `$GLOBALS['wp_php_rv']['bits'] = 64;`
|
1 |
+
## v160824.6416
|
2 |
+
|
3 |
+
- Bug fix. Array not initialized properly. See: #12
|
4 |
+
|
5 |
+
## v160712.42603
|
6 |
+
|
7 |
+
- **Bug fix:** Required PHP extension checks failing.
|
8 |
+
- **New Feature:** Now possible to require specific PHP functions too; e.g., `eval()`.
|
9 |
+
- Updating to latest phing build system.
|
10 |
+
- Updating dotfiles.
|
11 |
+
|
12 |
+
## v160531.14034
|
13 |
+
|
14 |
+
- Adding phing build files.
|
15 |
+
|
16 |
+
## v160524
|
17 |
+
|
18 |
+
- Adding support for an array of compatible operating systems.
|
19 |
+
- Adding support for a minimum version of WordPress.
|
20 |
+
- Adding support for a maximum version of WordPress.
|
21 |
+
|
22 |
## v160504
|
23 |
|
24 |
- Adding support for required bits via `$GLOBALS['wp_php_rv']['bits'] = 64;`
|
src/vendor/websharks/wp-php-rv/README.md
DELETED
@@ -1,97 +0,0 @@
|
|
1 |
-
## WP PHP vX.x+ (Version Check w/ Dashboard Notice)
|
2 |
-
|
3 |
-
Stub for WordPress themes/plugins that require PHP vX.x+ (i.e. a minimum version that you define).
|
4 |
-
|
5 |
-
![](assets/screenshot.png)
|
6 |
-
|
7 |
-
---
|
8 |
-
|
9 |
-
### Example Usage in a Typical WordPress Theme/Plugin File
|
10 |
-
|
11 |
-
```php
|
12 |
-
<?php
|
13 |
-
/*
|
14 |
-
Plugin Name: My Plugin
|
15 |
-
Plugin URI: http://example.com/my-plugin
|
16 |
-
Description: Example plugin.
|
17 |
-
Author: Example Author.
|
18 |
-
Version: 0.1-alpha
|
19 |
-
Author URI: http://example.com
|
20 |
-
Text Domain: my-plugin
|
21 |
-
*/
|
22 |
-
$GLOBALS['wp_php_rv'] = '5.3'; // Require PHP vX.x+ (you configure this).
|
23 |
-
if(require('wp-php-rv/src/includes/check.php')) // `true` if running PHP vX.x+.
|
24 |
-
require dirname(__FILE__).'/my-plugin-code.php'; // It's OK to load your plugin.
|
25 |
-
else wp_php_rv_notice(); // Creates a nice PHP vX.x+ dashboard notice for the site owner.
|
26 |
-
```
|
27 |
-
|
28 |
-
---
|
29 |
-
|
30 |
-
### Alternate Approach
|
31 |
-
|
32 |
-
The `check.php` file will automatically return `true` upon using `include()` or `require()` in your scripts; i.e., iff the installation site is running PHP vX.x+ (as configured by `$GLOBALS['wp_php_rv']`). Otherwise it returns `false`. Therefore, the simplest way to run your check is to use `if(require('wp-php-rv/src/includes/check.php'))`. **However**, you could also choose to do it this way.
|
33 |
-
|
34 |
-
```php
|
35 |
-
<?php
|
36 |
-
$GLOBALS['wp_php_rv'] = '5.3'; // Require PHP vX.x+.
|
37 |
-
require 'wp-php-rv/src/includes/check.php'; // Include.
|
38 |
-
|
39 |
-
if(wp_php_rv()) // `true` if running PHP vX.x+.
|
40 |
-
require dirname(__FILE__).'/my-plugin-code.php'; // It's OK to load your plugin.
|
41 |
-
else wp_php_rv_notice(); // Creates a nice PHP vX.x+ dashboard notice for the site owner.
|
42 |
-
```
|
43 |
-
|
44 |
-
---
|
45 |
-
|
46 |
-
### Dashboard Notice that Calls your Software by Name
|
47 |
-
|
48 |
-
```php
|
49 |
-
<?php
|
50 |
-
$GLOBALS['wp_php_rv'] = '5.3'; // Require PHP vX.x+.
|
51 |
-
if(require('wp-php-rv/src/includes/check.php')) // `true` if running PHP vX.x+.
|
52 |
-
require dirname(__FILE__).'/my-plugin-code.php'; // It's OK to load your plugin.
|
53 |
-
else wp_php_rv_notice('My Plugin'); // Dashboard notice mentions your software specifically.
|
54 |
-
```
|
55 |
-
|
56 |
-
**Note:** If you omit the `$brand_name` argument, a default value is used instead. The default value is `ucwords('[calling file basedir]')`; e.g., if `/my-plugin/stub.php` calls `wp-php-rv/src/includes/check.php`, the default `$software_name` automatically becomes `My Plugin`. Nice!
|
57 |
-
|
58 |
-
---
|
59 |
-
|
60 |
-
### What if Multiple Themes/Plugins Use This?
|
61 |
-
|
62 |
-
This is fine! :-) The `wp-php-rv/src/includes/check.php` file uses `function_exists()` as a wrapper; which allows it to be included any number of times, and by any number of plugins; and also from any number of locations. **The only thing to remember**, is that you MUST be sure to define `$GLOBALS['wp_php_rv']` each time; i.e., each time you `include('wp-php-rv/src/includes/check.php')` or `require('wp-php-rv/src/includes/check.php')`.
|
63 |
-
|
64 |
-
The point here, is that `$GLOBALS['wp_php_rv']` defines a PHP version that is specific to your plugin requirements, so it should be defined explicitly by each plugin developer before they `include('wp-php-rv/src/includes/check.php')` or `require('wp-php-rv/src/includes/check.php')`.
|
65 |
-
|
66 |
-
---
|
67 |
-
|
68 |
-
### Can this Just Go at the Top of My Existing Theme/Plugin File?
|
69 |
-
|
70 |
-
**No, there are two important things to remember.**
|
71 |
-
|
72 |
-
1. Don't forget to bundle a copy of the `websharks/wp-php-rv` repo with your theme/plugin. All you really need is the `/src` directory.
|
73 |
-
2. Don't leave your existing code in the same file. Use this in a stub file that checks for PHP vX.x+ first (as seen in the examples above), BEFORE loading your code which depends on PHP vX.x+. Why? If you put a PHP vX.x+ check at the top of an existing PHP file, and that particular PHP file happens to contain code which is only valid in PHP v5.2 (for instance), it may still trigger a syntax error. For this reason, you should move your code into a separate file and create a stub file that checks for the existence of PHP vX.x+ first.
|
74 |
-
|
75 |
-
---
|
76 |
-
|
77 |
-
### Can I Test for Required PHP Extensions Too?
|
78 |
-
|
79 |
-
Yes, `$GLOBALS['wp_php_rv']` can be either a string with a required version, or an array with both a required version and a nested array of required PHP extensions. The easiest way to show how this works is by example (as seen below). Note that your array of required PHP extensions must be compatible with PHP's [`extension_loaded()`](http://php.net/manual/en/function.extension-loaded.php) function.
|
80 |
-
|
81 |
-
```php
|
82 |
-
<?php
|
83 |
-
$GLOBALS['wp_php_rv']['min'] = '5.3';
|
84 |
-
// $GLOBALS['wp_php_rv']['max'] = '7.0.4';
|
85 |
-
// $GLOBALS['wp_php_rv']['bits'] = 64;
|
86 |
-
$GLOBALS['wp_php_rv']['extensions'] = array('curl', 'mbstring');
|
87 |
-
|
88 |
-
if(require('wp-php-rv/src/includes/check.php')) // `true` if running PHP vX.x+ w/ all required extensions.
|
89 |
-
require dirname(__FILE__).'/my-plugin-code.php'; // It's OK to load your plugin.
|
90 |
-
else wp_php_rv_notice('My Plugin'); // Dashboard notice mentions your software specifically.
|
91 |
-
```
|
92 |
-
|
93 |
-
---
|
94 |
-
|
95 |
-
Copyright: © 2015 [WebSharks, Inc.](http://www.websharks-inc.com/bizdev/) (coded in the USA)
|
96 |
-
|
97 |
-
Released under the terms of the [GNU General Public License](http://www.gnu.org/licenses/gpl-3.0.html).
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
src/vendor/websharks/wp-php-rv/src/includes/functions/.load.php
CHANGED
@@ -11,5 +11,6 @@
|
|
11 |
/*
|
12 |
* Load all functions.
|
13 |
*/
|
|
|
14 |
require_once dirname(__FILE__).'/checks.php';
|
15 |
require_once dirname(__FILE__).'/notices.php';
|
11 |
/*
|
12 |
* Load all functions.
|
13 |
*/
|
14 |
+
require_once dirname(__FILE__).'/utils.php';
|
15 |
require_once dirname(__FILE__).'/checks.php';
|
16 |
require_once dirname(__FILE__).'/notices.php';
|
src/vendor/websharks/wp-php-rv/src/includes/functions/checks.php
CHANGED
@@ -9,75 +9,149 @@
|
|
9 |
*/
|
10 |
|
11 |
/**
|
12 |
-
*
|
13 |
*
|
14 |
* @since 141004 First documented version.
|
15 |
*
|
16 |
-
* @return bool True if
|
17 |
*/
|
18 |
-
function wp_php_rv()
|
19 |
{
|
20 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
21 |
___wp_php_rv_initialize();
|
22 |
}
|
23 |
-
$
|
24 |
-
$
|
25 |
-
$
|
26 |
-
$
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
27 |
|
28 |
-
|
29 |
-
return false;
|
30 |
-
} elseif ($max_version && version_compare(PHP_VERSION, $max_version, '>')) {
|
31 |
-
return false;
|
32 |
-
} elseif ($minimum_bits && $minimum_bits / 8 > PHP_INT_SIZE) {
|
33 |
-
return false;
|
34 |
-
} elseif ($required_extensions) {
|
35 |
-
foreach ($required_extensions as $_required_extension) {
|
36 |
if (!extension_loaded($_required_extension)) {
|
37 |
-
|
38 |
-
}
|
39 |
} // unset($_required_extension); // Housekeeping.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
40 |
}
|
41 |
-
|
|
|
|
|
|
|
|
|
|
|
42 |
}
|
43 |
|
44 |
/**
|
45 |
-
* Initializes each instance; unsets `$
|
46 |
*
|
47 |
* @since 141004 First documented version.
|
48 |
*
|
49 |
-
* @note `$
|
50 |
-
* The internal global is defined here: `$
|
51 |
*/
|
52 |
function ___wp_php_rv_initialize()
|
53 |
{
|
54 |
-
$
|
55 |
-
|
|
|
|
|
|
|
|
|
56 |
'max' => '',
|
57 |
'bits' => 0,
|
|
|
58 |
'extensions' => array(),
|
|
|
|
|
|
|
|
|
59 |
);
|
60 |
-
if (!empty($
|
61 |
-
if (is_string($
|
62 |
-
$
|
63 |
-
} elseif (is_array($
|
64 |
-
if (!empty($
|
65 |
-
$
|
66 |
-
}
|
67 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
68 |
}
|
69 |
-
if (!empty($
|
70 |
-
$
|
|
|
|
|
71 |
}
|
72 |
-
if (!empty($
|
73 |
-
$
|
74 |
}
|
75 |
-
if (!empty($
|
76 |
-
$
|
77 |
-
} elseif (!empty($GLOBALS['wp_php_rv']['re'])) {
|
78 |
-
$GLOBALS['___wp_php_rv']['extensions'] = (array) $GLOBALS['wp_php_rv']['re'];
|
79 |
}
|
80 |
}
|
81 |
} // End of API conversion to internal global settings.
|
82 |
-
|
83 |
}
|
9 |
*/
|
10 |
|
11 |
/**
|
12 |
+
* Any compatibility issue?
|
13 |
*
|
14 |
* @since 141004 First documented version.
|
15 |
*
|
16 |
+
* @return bool True if no issue.
|
17 |
*/
|
18 |
+
function wp_php_rv() // See below.
|
19 |
{
|
20 |
+
return ___wp_php_rv_issue() ? false : true;
|
21 |
+
}
|
22 |
+
|
23 |
+
/**
|
24 |
+
* Any compatibility issue?
|
25 |
+
*
|
26 |
+
* @since 141004 First documented version.
|
27 |
+
*
|
28 |
+
* @return array Issue; else empty array.
|
29 |
+
*/
|
30 |
+
function ___wp_php_rv_issue()
|
31 |
+
{
|
32 |
+
global $wp_php_rv;
|
33 |
+
global $___wp_php_rv;
|
34 |
+
global $wp_version;
|
35 |
+
|
36 |
+
if (isset($wp_php_rv)) {
|
37 |
___wp_php_rv_initialize();
|
38 |
}
|
39 |
+
$required_os = $___wp_php_rv['os'];
|
40 |
+
$php_min_version = $___wp_php_rv['min'];
|
41 |
+
$php_max_version = $___wp_php_rv['max'];
|
42 |
+
$php_minimum_bits = $___wp_php_rv['bits'];
|
43 |
+
$php_required_functions = $___wp_php_rv['functions'];
|
44 |
+
$php_required_extensions = $___wp_php_rv['extensions'];
|
45 |
+
$wp_min_version = $___wp_php_rv['wp']['min'];
|
46 |
+
$wp_max_version = $___wp_php_rv['wp']['max'];
|
47 |
+
|
48 |
+
if ($required_os && ___wp_php_rv_os() !== $required_os) {
|
49 |
+
return array('reason' => 'os-incompatible');
|
50 |
+
} elseif ($php_min_version && version_compare(PHP_VERSION, $php_min_version, '<')) {
|
51 |
+
return array('reason' => 'php-needs-upgrade');
|
52 |
+
} elseif ($php_max_version && version_compare(PHP_VERSION, $php_max_version, '>')) {
|
53 |
+
return array('reason' => 'php-needs-downgrade');
|
54 |
+
} elseif ($php_minimum_bits && $php_minimum_bits / 8 > PHP_INT_SIZE) {
|
55 |
+
return array('reason' => 'php-missing-bits');
|
56 |
+
}
|
57 |
+
if ($php_required_functions) { // Requires PHP functions?
|
58 |
+
$php_missing_functions = array(); // Initialize.
|
59 |
+
|
60 |
+
foreach ($php_required_functions as $_required_function) {
|
61 |
+
if (!___wp_php_rv_can_call_func($_required_function)) {
|
62 |
+
$php_missing_functions[] = $_required_function;
|
63 |
+
} // See also: <http://jas.xyz/29Bdz3N>
|
64 |
+
} // unset($_required_function); // Housekeeping.
|
65 |
+
|
66 |
+
if ($php_missing_functions) { // Missing PHP functions?
|
67 |
+
return array(
|
68 |
+
'php_missing_functions' => $php_missing_functions,
|
69 |
+
'reason' => 'php-missing-functions',
|
70 |
+
);
|
71 |
+
}
|
72 |
+
}
|
73 |
+
if ($php_required_extensions) { // Requires PHP extensions?
|
74 |
+
$php_missing_extensions = array(); // Initialize.
|
75 |
|
76 |
+
foreach ($php_required_extensions as $_required_extension) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
77 |
if (!extension_loaded($_required_extension)) {
|
78 |
+
$php_missing_extensions[] = $_required_extension;
|
79 |
+
} // See also: <http://jas.xyz/1TtzgX5>
|
80 |
} // unset($_required_extension); // Housekeeping.
|
81 |
+
|
82 |
+
if ($php_missing_extensions) { // Missing PHP extensions?
|
83 |
+
return array(
|
84 |
+
'php_missing_extensions' => $php_missing_extensions,
|
85 |
+
'reason' => 'php-missing-extensions',
|
86 |
+
);
|
87 |
+
}
|
88 |
}
|
89 |
+
if ($wp_min_version && version_compare($wp_version, $wp_min_version, '<')) {
|
90 |
+
return array('reason' => 'wp-needs-upgrade');
|
91 |
+
} elseif ($wp_max_version && version_compare($wp_version, $wp_max_version, '>')) {
|
92 |
+
return array('reason' => 'wp-needs-downgrade');
|
93 |
+
}
|
94 |
+
return array(); // No problem.
|
95 |
}
|
96 |
|
97 |
/**
|
98 |
+
* Initializes each instance; unsets `$wp_php_rv`.
|
99 |
*
|
100 |
* @since 141004 First documented version.
|
101 |
*
|
102 |
+
* @note `$wp_php_rv` is for the API, we use a different variable internally.
|
103 |
+
* The internal global is defined here: `$___wp_php_rv`.
|
104 |
*/
|
105 |
function ___wp_php_rv_initialize()
|
106 |
{
|
107 |
+
global $wp_php_rv;
|
108 |
+
global $___wp_php_rv;
|
109 |
+
|
110 |
+
$___wp_php_rv = array(
|
111 |
+
'os' => '',
|
112 |
+
'min' => '',
|
113 |
'max' => '',
|
114 |
'bits' => 0,
|
115 |
+
'functions' => array(),
|
116 |
'extensions' => array(),
|
117 |
+
'wp' => array(
|
118 |
+
'min' => '',
|
119 |
+
'max' => '',
|
120 |
+
),
|
121 |
);
|
122 |
+
if (!empty($wp_php_rv)) {
|
123 |
+
if (is_string($wp_php_rv)) {
|
124 |
+
$___wp_php_rv['min'] = $wp_php_rv;
|
125 |
+
} elseif (is_array($wp_php_rv)) {
|
126 |
+
if (!empty($wp_php_rv['os'])) {
|
127 |
+
$___wp_php_rv['os'] = (string) $wp_php_rv['os'];
|
128 |
+
}
|
129 |
+
if (!empty($wp_php_rv['min'])) {
|
130 |
+
$___wp_php_rv['min'] = (string) $wp_php_rv['min'];
|
131 |
+
} elseif (!empty($wp_php_rv['rv'])) {
|
132 |
+
$___wp_php_rv['min'] = (string) $wp_php_rv['rv'];
|
133 |
+
}
|
134 |
+
if (!empty($wp_php_rv['max'])) {
|
135 |
+
$___wp_php_rv['max'] = (string) $wp_php_rv['max'];
|
136 |
+
}
|
137 |
+
if (!empty($wp_php_rv['bits'])) {
|
138 |
+
$___wp_php_rv['bits'] = (int) $wp_php_rv['bits'];
|
139 |
+
}
|
140 |
+
if (!empty($wp_php_rv['functions'])) {
|
141 |
+
$___wp_php_rv['functions'] = (array) $wp_php_rv['functions'];
|
142 |
}
|
143 |
+
if (!empty($wp_php_rv['extensions'])) {
|
144 |
+
$___wp_php_rv['extensions'] = (array) $wp_php_rv['extensions'];
|
145 |
+
} elseif (!empty($wp_php_rv['re'])) {
|
146 |
+
$___wp_php_rv['extensions'] = (array) $wp_php_rv['re'];
|
147 |
}
|
148 |
+
if (!empty($wp_php_rv['wp']['min'])) {
|
149 |
+
$___wp_php_rv['wp']['min'] = (string) $wp_php_rv['wp']['min'];
|
150 |
}
|
151 |
+
if (!empty($wp_php_rv['wp']['max'])) {
|
152 |
+
$___wp_php_rv['wp']['max'] = (string) $wp_php_rv['wp']['max'];
|
|
|
|
|
153 |
}
|
154 |
}
|
155 |
} // End of API conversion to internal global settings.
|
156 |
+
$wp_php_rv = null; // Unset to avoid theme/plugin conflicts.
|
157 |
}
|
src/vendor/websharks/wp-php-rv/src/includes/functions/notices.php
CHANGED
@@ -23,7 +23,11 @@ function wp_php_rv_custom_notice()
|
|
23 |
*/
|
24 |
function wp_php_rv_notice($brand_name = '')
|
25 |
{
|
26 |
-
|
|
|
|
|
|
|
|
|
27 |
___wp_php_rv_initialize();
|
28 |
}
|
29 |
# Only in the admin area.
|
@@ -36,42 +40,32 @@ function wp_php_rv_notice($brand_name = '')
|
|
36 |
if (!($brand_name = (string) $brand_name)) {
|
37 |
$brand_name = ___wp_php_rv_notice_brand_name();
|
38 |
} // If brand name detection fails too, use generic.
|
39 |
-
$brand_name = $brand_name ? $brand_name : 'This Software';
|
40 |
-
|
41 |
-
# Current
|
42 |
-
|
43 |
-
$
|
44 |
-
$
|
45 |
-
$
|
46 |
-
$
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
$
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
$reason = 'needs-downgrade';
|
56 |
-
} elseif ($minimum_bits && $minimum_bits / 8 > PHP_INT_SIZE) {
|
57 |
-
$reason = 'missing-bits';
|
58 |
-
} elseif ($required_extensions) {
|
59 |
-
foreach ($required_extensions as $_required_extension) {
|
60 |
-
if (!extension_loaded($_required_extension)) {
|
61 |
-
$reason = 'missing-extensions';
|
62 |
-
$missing_extensions[] = $_required_extension;
|
63 |
-
}
|
64 |
-
} // unset($_required_extension); // Housekeeping.
|
65 |
-
}
|
66 |
-
if (empty($reason)) {
|
67 |
return; // Nothing to do here.
|
68 |
-
}
|
|
|
|
|
69 |
# Fill-in additional variables needed down below.
|
70 |
|
71 |
$action = 'all_admin_notices';
|
72 |
$action_priority = 10; // Default priority.
|
73 |
|
74 |
-
$
|
75 |
? strstr(PHP_VERSION, '+', true) : PHP_VERSION;
|
76 |
// e.g., minus `+donate.sury.org~trusty+1`, etc.
|
77 |
|
@@ -93,53 +87,100 @@ function wp_php_rv_notice($brand_name = '')
|
|
93 |
|
94 |
switch ($reason) { // Based on reason.
|
95 |
|
96 |
-
case '
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
97 |
$markup = '<p style="font-weight:bold; font-size:125%; margin:.25em 0 0 0;">';
|
98 |
$markup .= __('PHP Upgrade Required', 'wp-php-rv');
|
99 |
$markup .= '</p>';
|
100 |
$markup .= '<p style="margin:0 0 .5em 0;">';
|
101 |
-
$markup .= $icon.sprintf(__('<strong>%1$s is not active.</strong> It requires PHP v%2$s (or higher).', 'wp-php-rv'), esc_html($brand_name), esc_html($
|
102 |
-
$markup .= sprintf(__('You\'re currently running the older PHP v%1$s, which is not supported by %2$s.', 'wp-php-rv'), esc_html($
|
103 |
$markup .= $arrow.' '.__('An update is necessary. <strong>Please contact your hosting company for assistance</strong>.', 'wp-php-rv').'<br />';
|
104 |
$markup .= sprintf(__('<em style="font-size:80%%; opacity:.7;">To remove this message, upgrade PHP or remove %1$s from WordPress.</em>', 'wp-php-rv'), esc_html($brand_name));
|
105 |
$markup .= '</p>';
|
106 |
break; // All done here.
|
107 |
|
108 |
-
case 'needs-downgrade': // Downgrade to older version of PHP.
|
109 |
$markup = '<p style="font-weight:bold; font-size:125%; margin:.25em 0 0 0;">';
|
110 |
$markup .= __('PHP Downgrade Required', 'wp-php-rv');
|
111 |
$markup .= '</p>';
|
112 |
$markup .= '<p style="margin:0 0 .5em 0;">';
|
113 |
$markup .= $icon.sprintf(__('<strong>%1$s is not active.</strong> It requires an older version of PHP.', 'wp-php-rv'), esc_html($brand_name)).'<br />';
|
114 |
-
$markup .= sprintf(__('This software is compatible up to PHP v%1$s, but you\'re running the newer PHP v%2$s.', 'wp-php-rv'), esc_html($
|
115 |
$markup .= $arrow.' '.__('A downgrade is necessary. <strong>Please contact your hosting company for assistance</strong>.', 'wp-php-rv').'<br />';
|
116 |
$markup .= sprintf(__('<em style="font-size:80%%; opacity:.7;">To remove this message, downgrade PHP or remove %1$s from WordPress.</em>', 'wp-php-rv'), esc_html($brand_name));
|
117 |
$markup .= '</p>';
|
118 |
break; // All done here.
|
119 |
|
120 |
-
case 'missing-bits': // Upgrade to a more powerful architecture.
|
121 |
$markup = '<p style="font-weight:bold; font-size:125%; margin:.25em 0 0 0;">';
|
122 |
$markup .= __('System Upgrade Required', 'wp-php-rv');
|
123 |
$markup .= '</p>';
|
124 |
$markup .= '<p style="margin:0 0 .5em 0;">';
|
125 |
-
$markup .= $icon.sprintf(__('<strong>%1$s is not active.</strong> It requires PHP on a %2$s-bit+ architecture.', 'wp-php-rv'), esc_html($brand_name), esc_html($
|
126 |
$markup .= sprintf(__('You\'re running an older %1$s-bit architecture, which is not supported by %2$s.', 'wp-php-rv'), esc_html(PHP_INT_SIZE * 8), esc_html($brand_name)).'<br />';
|
127 |
$markup .= $arrow.' '.__('An update is necessary. <strong>Please contact your hosting company for assistance</strong>.', 'wp-php-rv').'<br />';
|
128 |
$markup .= sprintf(__('<em style="font-size:80%%; opacity:.7;">To remove this message, upgrade your system or remove %1$s from WordPress.</em>', 'wp-php-rv'), esc_html($brand_name));
|
129 |
$markup .= '</p>';
|
130 |
break; // All done here.
|
131 |
|
132 |
-
case 'missing-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
133 |
$markup = '<p style="font-weight:bold; font-size:125%; margin:.25em 0 0 0;">';
|
134 |
$markup .= __('PHP Extension(s) Missing', 'wp-php-rv');
|
135 |
$markup .= '</p>';
|
136 |
$markup .= '<p style="margin:0 0 .5em 0;">';
|
137 |
-
$markup .= $icon.sprintf(__('<strong>%1$s is not active.</strong> It depends on PHP extension(s): %2$s.', 'wp-php-rv'), esc_html($brand_name), '<code>'.implode('</code>, <code>', array_map('esc_html', $
|
138 |
$markup .= $arrow.' '.__('An action is necessary. <strong>Please contact your hosting company for assistance</strong>.', 'wp-php-rv').'<br />';
|
139 |
$markup .= sprintf(__('<em style="font-size:80%%; opacity:.7;">To remove this message, enable missing extension(s) or remove %1$s from WordPress.</em>', 'wp-php-rv'), esc_html($brand_name));
|
140 |
$markup .= '</p>';
|
141 |
break; // All done here.
|
142 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
143 |
default: // Default case handler; i.e., anything else.
|
144 |
return; // Nothing to do here.
|
145 |
}
|
@@ -154,9 +195,17 @@ function wp_php_rv_notice($brand_name = '')
|
|
154 |
|
155 |
# Attach an action to display the notice now.
|
156 |
|
157 |
-
add_action($action, create_function(
|
158 |
'',
|
|
|
|
|
159 |
'if (!current_user_can(\'activate_plugins\')) return;'.
|
|
|
|
|
|
|
|
|
|
|
|
|
160 |
'if (!apply_filters(\'wp_php_rv_notice_display\', true, get_defined_vars())) return;'.
|
161 |
|
162 |
'echo \''.// Wrap `$markup` inside a WordPress warning.
|
23 |
*/
|
24 |
function wp_php_rv_notice($brand_name = '')
|
25 |
{
|
26 |
+
global $wp_php_rv;
|
27 |
+
global $___wp_php_rv;
|
28 |
+
global $wp_version;
|
29 |
+
|
30 |
+
if (isset($wp_php_rv)) {
|
31 |
___wp_php_rv_initialize();
|
32 |
}
|
33 |
# Only in the admin area.
|
40 |
if (!($brand_name = (string) $brand_name)) {
|
41 |
$brand_name = ___wp_php_rv_notice_brand_name();
|
42 |
} // If brand name detection fails too, use generic.
|
43 |
+
$brand_name = $brand_name ? $brand_name : __('This Software', 'wp-php-rv');
|
44 |
+
|
45 |
+
# Current requirements/dependencies.
|
46 |
+
|
47 |
+
$required_os = $___wp_php_rv['os'];
|
48 |
+
$php_min_version = $___wp_php_rv['min'];
|
49 |
+
$php_max_version = $___wp_php_rv['max'];
|
50 |
+
$php_minimum_bits = $___wp_php_rv['bits'];
|
51 |
+
$php_required_functions = $___wp_php_rv['functions'];
|
52 |
+
$php_required_extensions = $___wp_php_rv['extensions'];
|
53 |
+
$wp_min_version = $___wp_php_rv['wp']['min'];
|
54 |
+
$wp_max_version = $___wp_php_rv['wp']['max'];
|
55 |
+
|
56 |
+
# Determine reason for dependency failure.
|
57 |
+
|
58 |
+
if (!($issue = ___wp_php_rv_issue())) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
59 |
return; // Nothing to do here.
|
60 |
+
} // If there is no issue we can stop here.
|
61 |
+
extract($issue); // `reason`, `php_missing_functions`, `php_missing_extensions`.
|
62 |
+
|
63 |
# Fill-in additional variables needed down below.
|
64 |
|
65 |
$action = 'all_admin_notices';
|
66 |
$action_priority = 10; // Default priority.
|
67 |
|
68 |
+
$php_version = strpos(PHP_VERSION, '+') !== false
|
69 |
? strstr(PHP_VERSION, '+', true) : PHP_VERSION;
|
70 |
// e.g., minus `+donate.sury.org~trusty+1`, etc.
|
71 |
|
87 |
|
88 |
switch ($reason) { // Based on reason.
|
89 |
|
90 |
+
case 'os-incompatible': // OS incomaptible.
|
91 |
+
$markup = '<p style="font-weight:bold; font-size:125%; margin:.25em 0 0 0;">';
|
92 |
+
$markup .= __('Incompatible Operating System', 'wp-php-rv');
|
93 |
+
$markup .= '</p>';
|
94 |
+
$markup .= '<p style="margin:0 0 .5em 0;">';
|
95 |
+
$markup .= $icon.sprintf(__('<strong>%1$s is not active.</strong> It requires a %2$s operating system.', 'wp-php-rv'), esc_html($brand_name), esc_html(___wp_php_rv_os_name($required_os))).'<br />';
|
96 |
+
$markup .= sprintf(__('You\'re currently running %1$s, which is not supported by %2$s at this time.', 'wp-php-rv'), esc_html(PHP_OS), esc_html($brand_name)).'<br />';
|
97 |
+
$markup .= $arrow.' '.__('A compatible OS is necessary. <strong>Please contact your hosting company for assistance</strong>.', 'wp-php-rv').'<br />';
|
98 |
+
$markup .= sprintf(__('<em style="font-size:80%%; opacity:.7;">To remove this message, change the OS or remove %1$s from WordPress.</em>', 'wp-php-rv'), esc_html($brand_name));
|
99 |
+
$markup .= '</p>';
|
100 |
+
break; // All done here.
|
101 |
+
|
102 |
+
case 'php-needs-upgrade': // Upgrade to latest version of PHP.
|
103 |
$markup = '<p style="font-weight:bold; font-size:125%; margin:.25em 0 0 0;">';
|
104 |
$markup .= __('PHP Upgrade Required', 'wp-php-rv');
|
105 |
$markup .= '</p>';
|
106 |
$markup .= '<p style="margin:0 0 .5em 0;">';
|
107 |
+
$markup .= $icon.sprintf(__('<strong>%1$s is not active.</strong> It requires PHP v%2$s (or higher).', 'wp-php-rv'), esc_html($brand_name), esc_html($php_min_version)).'<br />';
|
108 |
+
$markup .= sprintf(__('You\'re currently running the older PHP v%1$s, which is not supported by %2$s.', 'wp-php-rv'), esc_html($php_version), esc_html($brand_name)).'<br />';
|
109 |
$markup .= $arrow.' '.__('An update is necessary. <strong>Please contact your hosting company for assistance</strong>.', 'wp-php-rv').'<br />';
|
110 |
$markup .= sprintf(__('<em style="font-size:80%%; opacity:.7;">To remove this message, upgrade PHP or remove %1$s from WordPress.</em>', 'wp-php-rv'), esc_html($brand_name));
|
111 |
$markup .= '</p>';
|
112 |
break; // All done here.
|
113 |
|
114 |
+
case 'php-needs-downgrade': // Downgrade to older version of PHP.
|
115 |
$markup = '<p style="font-weight:bold; font-size:125%; margin:.25em 0 0 0;">';
|
116 |
$markup .= __('PHP Downgrade Required', 'wp-php-rv');
|
117 |
$markup .= '</p>';
|
118 |
$markup .= '<p style="margin:0 0 .5em 0;">';
|
119 |
$markup .= $icon.sprintf(__('<strong>%1$s is not active.</strong> It requires an older version of PHP.', 'wp-php-rv'), esc_html($brand_name)).'<br />';
|
120 |
+
$markup .= sprintf(__('This software is compatible up to PHP v%1$s, but you\'re running the newer PHP v%2$s.', 'wp-php-rv'), esc_html($php_max_version), esc_html($php_version)).'<br />';
|
121 |
$markup .= $arrow.' '.__('A downgrade is necessary. <strong>Please contact your hosting company for assistance</strong>.', 'wp-php-rv').'<br />';
|
122 |
$markup .= sprintf(__('<em style="font-size:80%%; opacity:.7;">To remove this message, downgrade PHP or remove %1$s from WordPress.</em>', 'wp-php-rv'), esc_html($brand_name));
|
123 |
$markup .= '</p>';
|
124 |
break; // All done here.
|
125 |
|
126 |
+
case 'php-missing-bits': // Upgrade to a more powerful architecture.
|
127 |
$markup = '<p style="font-weight:bold; font-size:125%; margin:.25em 0 0 0;">';
|
128 |
$markup .= __('System Upgrade Required', 'wp-php-rv');
|
129 |
$markup .= '</p>';
|
130 |
$markup .= '<p style="margin:0 0 .5em 0;">';
|
131 |
+
$markup .= $icon.sprintf(__('<strong>%1$s is not active.</strong> It requires PHP on a %2$s-bit+ architecture.', 'wp-php-rv'), esc_html($brand_name), esc_html($php_minimum_bits)).'<br />';
|
132 |
$markup .= sprintf(__('You\'re running an older %1$s-bit architecture, which is not supported by %2$s.', 'wp-php-rv'), esc_html(PHP_INT_SIZE * 8), esc_html($brand_name)).'<br />';
|
133 |
$markup .= $arrow.' '.__('An update is necessary. <strong>Please contact your hosting company for assistance</strong>.', 'wp-php-rv').'<br />';
|
134 |
$markup .= sprintf(__('<em style="font-size:80%%; opacity:.7;">To remove this message, upgrade your system or remove %1$s from WordPress.</em>', 'wp-php-rv'), esc_html($brand_name));
|
135 |
$markup .= '</p>';
|
136 |
break; // All done here.
|
137 |
|
138 |
+
case 'php-missing-functions': // PHP is missing required functions.
|
139 |
+
$markup = '<p style="font-weight:bold; font-size:125%; margin:.25em 0 0 0;">';
|
140 |
+
$markup .= __('PHP Function(s) Missing', 'wp-php-rv');
|
141 |
+
$markup .= '</p>';
|
142 |
+
$markup .= '<p style="margin:0 0 .5em 0;">';
|
143 |
+
$markup .= $icon.sprintf(__('<strong>%1$s is not active.</strong> It depends on PHP function(s): %2$s.', 'wp-php-rv'), esc_html($brand_name), '<code>'.implode('</code>, <code>', array_map('esc_html', $php_missing_functions)).'</code>').'<br />';
|
144 |
+
$markup .= $arrow.' '.__('An action is necessary. <strong>Please contact your hosting company for assistance</strong>.', 'wp-php-rv').'<br />';
|
145 |
+
$markup .= sprintf(__('<em style="font-size:80%%; opacity:.7;">To remove this message, enable missing function(s) or remove %1$s from WordPress.</em>', 'wp-php-rv'), esc_html($brand_name));
|
146 |
+
$markup .= '</p>';
|
147 |
+
break; // All done here.
|
148 |
+
|
149 |
+
case 'php-missing-extensions': // PHP is missing required extensions.
|
150 |
$markup = '<p style="font-weight:bold; font-size:125%; margin:.25em 0 0 0;">';
|
151 |
$markup .= __('PHP Extension(s) Missing', 'wp-php-rv');
|
152 |
$markup .= '</p>';
|
153 |
$markup .= '<p style="margin:0 0 .5em 0;">';
|
154 |
+
$markup .= $icon.sprintf(__('<strong>%1$s is not active.</strong> It depends on PHP extension(s): %2$s.', 'wp-php-rv'), esc_html($brand_name), '<code>'.implode('</code>, <code>', array_map('esc_html', $php_missing_extensions)).'</code>').'<br />';
|
155 |
$markup .= $arrow.' '.__('An action is necessary. <strong>Please contact your hosting company for assistance</strong>.', 'wp-php-rv').'<br />';
|
156 |
$markup .= sprintf(__('<em style="font-size:80%%; opacity:.7;">To remove this message, enable missing extension(s) or remove %1$s from WordPress.</em>', 'wp-php-rv'), esc_html($brand_name));
|
157 |
$markup .= '</p>';
|
158 |
break; // All done here.
|
159 |
|
160 |
+
case 'wp-needs-upgrade': // Upgrade to latest version of WP.
|
161 |
+
$markup = '<p style="font-weight:bold; font-size:125%; margin:.25em 0 0 0;">';
|
162 |
+
$markup .= __('WP Upgrade Required', 'wp-php-rv');
|
163 |
+
$markup .= '</p>';
|
164 |
+
$markup .= '<p style="margin:0 0 .5em 0;">';
|
165 |
+
$markup .= $icon.sprintf(__('<strong>%1$s is not active.</strong> It requires WP v%2$s (or higher).', 'wp-php-rv'), esc_html($brand_name), esc_html($wp_min_version)).'<br />';
|
166 |
+
$markup .= sprintf(__('You\'re currently running the older WP v%1$s, which is not supported by %2$s.', 'wp-php-rv'), esc_html($wp_version), esc_html($brand_name)).'<br />';
|
167 |
+
$markup .= $arrow.' '.sprintf(__('An upgrade is necessary. <strong>Please <a href="%1$s">click here to upgrade now</a></strong>.', 'wp-php-rv'), esc_url(network_admin_url('/update-core.php'))).'<br />';
|
168 |
+
$markup .= sprintf(__('<em style="font-size:80%%; opacity:.7;">To remove this message, upgrade WordPress or deactivate %1$s.</em>', 'wp-php-rv'), esc_html($brand_name));
|
169 |
+
$markup .= '</p>';
|
170 |
+
break; // All done here.
|
171 |
+
|
172 |
+
case 'wp-needs-downgrade': // Downgrade to older version of WP.
|
173 |
+
$markup = '<p style="font-weight:bold; font-size:125%; margin:.25em 0 0 0;">';
|
174 |
+
$markup .= __('WP Downgrade Required', 'wp-php-rv');
|
175 |
+
$markup .= '</p>';
|
176 |
+
$markup .= '<p style="margin:0 0 .5em 0;">';
|
177 |
+
$markup .= $icon.sprintf(__('<strong>%1$s is not active.</strong> It requires an older version of WP.', 'wp-php-rv'), esc_html($brand_name)).'<br />';
|
178 |
+
$markup .= sprintf(__('This software is compatible up to WP v%1$s, but you\'re running the newer WP v%2$s.', 'wp-php-rv'), esc_html($wp_max_version), esc_html($wp_version)).'<br />';
|
179 |
+
$markup .= $arrow.' '.sprintf(__('A downgrade is necessary. <strong>Please see: <a href="%1$s">WordPress.org release archive</a></strong>.', 'wp-php-rv'), esc_url('https://wordpress.org/download/release-archive/')).'<br />';
|
180 |
+
$markup .= sprintf(__('<em style="font-size:80%%; opacity:.7;">To remove this message, downgrade WordPress or deactivate %1$s.</em>', 'wp-php-rv'), esc_html($brand_name));
|
181 |
+
$markup .= '</p>';
|
182 |
+
break; // All done here.
|
183 |
+
|
184 |
default: // Default case handler; i.e., anything else.
|
185 |
return; // Nothing to do here.
|
186 |
}
|
195 |
|
196 |
# Attach an action to display the notice now.
|
197 |
|
198 |
+
add_action($action, create_function(
|
199 |
'',
|
200 |
+
'global $pagenow;'.// Needed below.
|
201 |
+
|
202 |
'if (!current_user_can(\'activate_plugins\')) return;'.
|
203 |
+
|
204 |
+
'if (in_array($pagenow, array(\'update-core.php\'), true)) return;'.
|
205 |
+
'if (in_array($pagenow, array(\'plugins.php\', \'themes.php\', \'update.php\'), true)'.
|
206 |
+
' && !empty($_REQUEST[\'___action_via\']) && $_REQUEST[\'___action_via\'] === \'wp-php-rv\') return;'.
|
207 |
+
// Not during a core update, and not during a plugin install/activate/update.
|
208 |
+
|
209 |
'if (!apply_filters(\'wp_php_rv_notice_display\', true, get_defined_vars())) return;'.
|
210 |
|
211 |
'echo \''.// Wrap `$markup` inside a WordPress warning.
|
src/vendor/websharks/wp-php-rv/src/includes/functions/utils.php
ADDED
@@ -0,0 +1,101 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* PHP vX.x Handlers.
|
4 |
+
*
|
5 |
+
* @since 160503 Reorganizing structure.
|
6 |
+
*
|
7 |
+
* @copyright WebSharks, Inc. <http://websharks-inc.com>
|
8 |
+
* @license GNU General Public License, version 3
|
9 |
+
*/
|
10 |
+
|
11 |
+
/**
|
12 |
+
* OS detection.
|
13 |
+
*
|
14 |
+
* @since 160523 OS detection.
|
15 |
+
*
|
16 |
+
* @return string OS identifier.
|
17 |
+
*/
|
18 |
+
function ___wp_php_rv_os()
|
19 |
+
{
|
20 |
+
static $os; // Static cache.
|
21 |
+
|
22 |
+
if (isset($os)) {
|
23 |
+
return $os; // Cached already.
|
24 |
+
} elseif (stripos(PHP_OS, 'win') === 0) {
|
25 |
+
return $os = 'win';
|
26 |
+
} else {
|
27 |
+
return $os = 'nix';
|
28 |
+
}
|
29 |
+
}
|
30 |
+
|
31 |
+
/**
|
32 |
+
* OS long name.
|
33 |
+
*
|
34 |
+
* @since 160523 OS detection.
|
35 |
+
*
|
36 |
+
* @return string OS long name.
|
37 |
+
*/
|
38 |
+
function ___wp_php_rv_os_name($os)
|
39 |
+
{
|
40 |
+
if ($os === 'win') {
|
41 |
+
return 'Windows®';
|
42 |
+
} else {
|
43 |
+
return 'Unix-like';
|
44 |
+
}
|
45 |
+
}
|
46 |
+
|
47 |
+
/**
|
48 |
+
* Can call a PHP function?
|
49 |
+
*
|
50 |
+
* @since 160712 PHP functions.
|
51 |
+
*
|
52 |
+
* @return bool True if callable.
|
53 |
+
*/
|
54 |
+
function ___wp_php_rv_can_call_func($function)
|
55 |
+
{
|
56 |
+
static $can = array();
|
57 |
+
static $constructs = array(
|
58 |
+
'die',
|
59 |
+
'echo',
|
60 |
+
'empty',
|
61 |
+
'exit',
|
62 |
+
'eval',
|
63 |
+
'include',
|
64 |
+
'include_once',
|
65 |
+
'isset',
|
66 |
+
'list',
|
67 |
+
'require',
|
68 |
+
'require_once',
|
69 |
+
'return',
|
70 |
+
'print',
|
71 |
+
'unset',
|
72 |
+
'__halt_compiler',
|
73 |
+
);
|
74 |
+
static $functions_disabled; // Set below.
|
75 |
+
|
76 |
+
if (isset($can[$function = strtolower($function)])) {
|
77 |
+
return $can[$function]; // Already cached this.
|
78 |
+
}
|
79 |
+
if (!isset($functions_disabled)) {
|
80 |
+
$functions_disabled = array(); // Initialize.
|
81 |
+
|
82 |
+
if (($_ini_disable_functions = (string) @ini_get('disable_functions'))) {
|
83 |
+
$_ini_disable_functions = strtolower($_ini_disable_functions);
|
84 |
+
$functions_disabled = array_merge($functions_disabled, preg_split('/[\s;,]+/u', $_ini_disable_functions, -1, PREG_SPLIT_NO_EMPTY));
|
85 |
+
}
|
86 |
+
if (($_ini_suhosin_blacklist_functions = (string) @ini_get('suhosin.executor.func.blacklist'))) {
|
87 |
+
$_ini_suhosin_blacklist_functions = strtolower($_ini_suhosin_blacklist_functions);
|
88 |
+
$functions_disabled = array_merge($functions_disabled, preg_split('/[\s;,]+/u', $_ini_suhosin_blacklist_functions, -1, PREG_SPLIT_NO_EMPTY));
|
89 |
+
}
|
90 |
+
if (filter_var(@ini_get('suhosin.executor.disable_eval'), FILTER_VALIDATE_BOOLEAN)) {
|
91 |
+
$functions_disabled[] = 'eval'; // The `eval()` construct is disabled also.
|
92 |
+
}
|
93 |
+
} // We now have a full list of all disabled functions.
|
94 |
+
|
95 |
+
if ($functions_disabled && in_array($function, $functions_disabled, true)) {
|
96 |
+
return $can[$function] = false; // Not possible; e.g., `eval()`.
|
97 |
+
} elseif ((!function_exists($function) || !is_callable($function)) && !in_array($function, $constructs, true)) {
|
98 |
+
return $can[$function] = false; // Not possible.
|
99 |
+
}
|
100 |
+
return $can[$function] = true;
|
101 |
+
}
|