Version Description
= 2.0.10.9 = Important security update. Please upgrade immediately.
= 2.0 = New GPL plugin, now updates are through the wordpress.org repository
Download this release
Release Info
Developer | a2hosting |
Plugin | A2 Optimized WP |
Version | 2.1.3.10.2 |
Comparing to | |
See all releases |
Code changes from version 2.1.3.10.1 to 2.1.3.10.2
- A2_Optimized_SiteHealth.php +24 -1
- a2-optimized.php +1 -1
- readme.txt +1 -1
A2_Optimized_SiteHealth.php
CHANGED
@@ -455,7 +455,8 @@ class A2_Optimized_SiteHealth {
|
|
455 |
'test' => 'php_memory',
|
456 |
);
|
457 |
|
458 |
-
|
|
|
459 |
$result['status'] = 'recommended';
|
460 |
$result['label'] = ( 'PHP Memory should be increased' );
|
461 |
$result['description'] = sprintf(
|
@@ -754,4 +755,26 @@ class A2_Optimized_SiteHealth {
|
|
754 |
|
755 |
return $debug_info;
|
756 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
757 |
}
|
455 |
'test' => 'php_memory',
|
456 |
);
|
457 |
|
458 |
+
$memory_limit = $this->return_bytes(ini_get('memory_limit'));
|
459 |
+
if ($memory_limit < 134217727) { // 128mb
|
460 |
$result['status'] = 'recommended';
|
461 |
$result['label'] = ( 'PHP Memory should be increased' );
|
462 |
$result['description'] = sprintf(
|
755 |
|
756 |
return $debug_info;
|
757 |
}
|
758 |
+
|
759 |
+
/**
|
760 |
+
* Takes raw string with size shorthand (K/M/G) and return int of bytes
|
761 |
+
*
|
762 |
+
* @param string $val Shorthand string
|
763 |
+
*
|
764 |
+
* @return int Actual value in bytes
|
765 |
+
*/
|
766 |
+
private function return_bytes($val) {
|
767 |
+
$val = trim($val);
|
768 |
+
$last = strtolower($val[strlen($val)-1]);
|
769 |
+
switch($last) {
|
770 |
+
// The 'G' modifier is available
|
771 |
+
case 'g':
|
772 |
+
$val *= 1024;
|
773 |
+
case 'm':
|
774 |
+
$val *= 1024;
|
775 |
+
case 'k':
|
776 |
+
$val *= 1024;
|
777 |
+
}
|
778 |
+
return $val;
|
779 |
+
}
|
780 |
}
|
a2-optimized.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
/*
|
3 |
Plugin Name: A2 Optimized WP
|
4 |
Plugin URI: https://wordpress.org/plugins/a2-optimized/
|
5 |
-
Version: 2.1.3.10.
|
6 |
Author: A2 Hosting
|
7 |
Author URI: https://www.a2hosting.com/
|
8 |
Description: A2 Optimized - WordPress Optimization Plugin
|
2 |
/*
|
3 |
Plugin Name: A2 Optimized WP
|
4 |
Plugin URI: https://wordpress.org/plugins/a2-optimized/
|
5 |
+
Version: 2.1.3.10.2
|
6 |
Author: A2 Hosting
|
7 |
Author URI: https://www.a2hosting.com/
|
8 |
Description: A2 Optimized - WordPress Optimization Plugin
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: A2BCool, a2hosting, dmatteson, sputala
|
|
3 |
Tags: Speed, Optimize, Secure, Fast, LiteSpeed, LSCache, A2, Hosting
|
4 |
Requires at least: 5.1
|
5 |
Tested up to: 5.9
|
6 |
-
Stable tag: 2.1.3.10.
|
7 |
Requires PHP: 5.6
|
8 |
License: GPLv3
|
9 |
License URI: http://www.gnu.org/licenses/gpl-3.0.html
|
3 |
Tags: Speed, Optimize, Secure, Fast, LiteSpeed, LSCache, A2, Hosting
|
4 |
Requires at least: 5.1
|
5 |
Tested up to: 5.9
|
6 |
+
Stable tag: 2.1.3.10.2
|
7 |
Requires PHP: 5.6
|
8 |
License: GPLv3
|
9 |
License URI: http://www.gnu.org/licenses/gpl-3.0.html
|