WP-Memory-Usage - Version 1.2.5

Version Description

  • Plugin prepared for Translation, PO-File and de_DE-MO-File added
  • Wordpress-Multisite-Installations: Plugin now also in Network-Dashboard
  • Plugin ok with Worpdress 5.8.3
Download this release

Release Info

Developer berkux
Plugin Icon 128x128 WP-Memory-Usage
Version 1.2.5
Comparing to
See all releases

Code changes from version 1.2.4 to 1.2.5

languages/wp-memory-usage-de_DE.mo ADDED
Binary file
languages/wp-memory-usage-de_DE.po ADDED
@@ -0,0 +1,77 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ msgid ""
2
+ msgstr ""
3
+ "Project-Id-Version: wp-memory-usage\n"
4
+ "POT-Creation-Date: 2022-01-08 23:39+0100\n"
5
+ "PO-Revision-Date: 2022-01-08 23:40+0100\n"
6
+ "Last-Translator: \n"
7
+ "Language-Team: BKux\n"
8
+ "Language: de_DE\n"
9
+ "MIME-Version: 1.0\n"
10
+ "Content-Type: text/plain; charset=UTF-8\n"
11
+ "Content-Transfer-Encoding: 8bit\n"
12
+ "X-Generator: Poedit 2.4.2\n"
13
+ "X-Poedit-Basepath: ..\n"
14
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
15
+ "X-Poedit-KeywordsList: __\n"
16
+ "X-Poedit-SearchPath-0: readme.txt\n"
17
+ "X-Poedit-SearchPath-1: wp-memory-usage.php\n"
18
+
19
+ #: wp-memory-usage.php:115
20
+ msgid "PHP Version"
21
+ msgstr "PHP Version"
22
+
23
+ #: wp-memory-usage.php:116
24
+ msgid "Bit OS"
25
+ msgstr "Bit OS"
26
+
27
+ #: wp-memory-usage.php:119
28
+ msgid "sec"
29
+ msgstr "Sek"
30
+
31
+ #: wp-memory-usage.php:120
32
+ msgid "Max execution time: "
33
+ msgstr "Max Ausführungszeit: "
34
+
35
+ #: wp-memory-usage.php:125
36
+ msgid "Memory limits"
37
+ msgstr "Speicherlimit"
38
+
39
+ #: wp-memory-usage.php:128
40
+ msgid "Wordpress"
41
+ msgstr "Wordpress"
42
+
43
+ #: wp-memory-usage.php:134
44
+ msgid "PHP "
45
+ msgstr ""
46
+
47
+ #: wp-memory-usage.php:138
48
+ msgid "Memory usage"
49
+ msgstr "Speichernutzung"
50
+
51
+ #: wp-memory-usage.php:156
52
+ msgid "Memory Overview"
53
+ msgstr "Speicherüberblick"
54
+
55
+ #: wp-memory-usage.php:156
56
+ msgid "Servertime"
57
+ msgstr "Serverzeit"
58
+
59
+ #: wp-memory-usage.php:186
60
+ msgid "WP Memory Limit:"
61
+ msgstr "WP Speicherlimit:"
62
+
63
+ #: wp-memory-usage.php:186 wp-memory-usage.php:187
64
+ msgid "of"
65
+ msgstr "von"
66
+
67
+ #: wp-memory-usage.php:187
68
+ msgid "PHP Memory Limit:"
69
+ msgstr "PHP Speicherlimit:"
70
+
71
+ #: wp-memory-usage.php:188
72
+ msgid "IP-Address"
73
+ msgstr "IP-Adresse"
74
+
75
+ #: wp-memory-usage.php:189
76
+ msgid "PHP"
77
+ msgstr "PHP"
languages/wp-memory-usage-de_DE.pot ADDED
@@ -0,0 +1,78 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #, fuzzy
2
+ msgid ""
3
+ msgstr ""
4
+ "Project-Id-Version: wp-memory-usage\n"
5
+ "POT-Creation-Date: 2022-01-08 23:39+0100\n"
6
+ "PO-Revision-Date: 2022-01-03 21:45+0100\n"
7
+ "Last-Translator: \n"
8
+ "Language-Team: BKux\n"
9
+ "Language: de_DE\n"
10
+ "MIME-Version: 1.0\n"
11
+ "Content-Type: text/plain; charset=UTF-8\n"
12
+ "Content-Transfer-Encoding: 8bit\n"
13
+ "X-Generator: Poedit 2.4.2\n"
14
+ "X-Poedit-Basepath: ..\n"
15
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
16
+ "X-Poedit-KeywordsList: __\n"
17
+ "X-Poedit-SearchPath-0: readme.txt\n"
18
+ "X-Poedit-SearchPath-1: wp-memory-usage.php\n"
19
+
20
+ #: wp-memory-usage.php:115
21
+ msgid "PHP Version"
22
+ msgstr ""
23
+
24
+ #: wp-memory-usage.php:116
25
+ msgid "Bit OS"
26
+ msgstr ""
27
+
28
+ #: wp-memory-usage.php:119
29
+ msgid "sec"
30
+ msgstr ""
31
+
32
+ #: wp-memory-usage.php:120
33
+ msgid "Max execution time: "
34
+ msgstr ""
35
+
36
+ #: wp-memory-usage.php:125
37
+ msgid "Memory limits"
38
+ msgstr ""
39
+
40
+ #: wp-memory-usage.php:128
41
+ msgid "Wordpress"
42
+ msgstr ""
43
+
44
+ #: wp-memory-usage.php:134
45
+ msgid "PHP "
46
+ msgstr ""
47
+
48
+ #: wp-memory-usage.php:138
49
+ msgid "Memory usage"
50
+ msgstr ""
51
+
52
+ #: wp-memory-usage.php:156
53
+ msgid "Memory Overview"
54
+ msgstr ""
55
+
56
+ #: wp-memory-usage.php:156
57
+ msgid "Servertime"
58
+ msgstr ""
59
+
60
+ #: wp-memory-usage.php:186
61
+ msgid "WP Memory Limit:"
62
+ msgstr ""
63
+
64
+ #: wp-memory-usage.php:186 wp-memory-usage.php:187
65
+ msgid "of"
66
+ msgstr ""
67
+
68
+ #: wp-memory-usage.php:187
69
+ msgid "PHP Memory Limit:"
70
+ msgstr ""
71
+
72
+ #: wp-memory-usage.php:188
73
+ msgid "IP-Address"
74
+ msgstr ""
75
+
76
+ #: wp-memory-usage.php:189
77
+ msgid "PHP"
78
+ msgstr ""
languages/wp-memory-usage_de_DE.mo DELETED
Binary file
readme.txt CHANGED
@@ -2,9 +2,10 @@
2
  Contributors: berkux
3
  Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=APWXWK3DF2E22
4
  Tags: memory, admin, php, memory-limit, ip, ips, adress, php, server, info
 
5
  Requires at least: 5.3
6
- Tested up to: 5.8.2
7
- Stable tag: 1.2.4
8
  License: GPLv3
9
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
10
 
@@ -12,7 +13,16 @@ Show up the PHP version, memory limit and current memory usage in the dashboard
12
 
13
  == Description ==
14
 
15
- Show up the PHP version, memory limit and current memory usage in the dashboard and admin footer. You can now simple measure the requirements of your plugins and language files.
 
 
 
 
 
 
 
 
 
16
  <a href="https://profiles.wordpress.org/alexrabe/">The plugin was transferred from alexrabe to berkux on Jan 2 2022</a>
17
 
18
  == Credits ==
@@ -26,6 +36,11 @@ Copyright 2009-2013 by Alex Rabe, 2022- Bernhard Kux
26
  1. Screenshot Admin footer
27
 
28
  == Changelog ==
 
 
 
 
 
29
  = 1.2.4 =
30
  * Reengineered: Used newer functions to measure memory etc.
31
  * consider different Wordpress- and PHP-Memorylimits
2
  Contributors: berkux
3
  Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=APWXWK3DF2E22
4
  Tags: memory, admin, php, memory-limit, ip, ips, adress, php, server, info
5
+ Requires PHP: 5.3.0
6
  Requires at least: 5.3
7
+ Tested up to: 5.9
8
+ Stable tag: 1.2.5
9
  License: GPLv3
10
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
11
 
13
 
14
  == Description ==
15
 
16
+ * Purpose of the plugin
17
+ You can simple measure the settings of your Webserver and Wordpress-Installation. This is very helppful to check the requirements of your Website, your Wordpress and it's plugins
18
+
19
+ * What is displayed?
20
+ PHP version, memory limit and current memory usage
21
+
22
+ * Where is it displayed?
23
+ On the dashboard and the admin footer.
24
+
25
+ * History of the Plugin
26
  <a href="https://profiles.wordpress.org/alexrabe/">The plugin was transferred from alexrabe to berkux on Jan 2 2022</a>
27
 
28
  == Credits ==
36
  1. Screenshot Admin footer
37
 
38
  == Changelog ==
39
+ = 1.2.5 =
40
+ * Plugin prepared for Translation, PO-File and de_DE-MO-File added
41
+ * Wordpress-Multisite-Installations: Plugin now also in Network-Dashboard
42
+ * Plugin ok with Worpdress 5.8.3
43
+
44
  = 1.2.4 =
45
  * Reengineered: Used newer functions to measure memory etc.
46
  * consider different Wordpress- and PHP-Memorylimits
wp-memory-usage.php CHANGED
@@ -4,7 +4,7 @@ Plugin Name: WP-Memory-Usage
4
  Plugin URI: https://www.json-content-importer.com
5
  Description: Show up memory limits, current memory usage, IP-Address, PHP-Version in the dashboard and admin footer
6
  Author: Bernhard Kux
7
- Version: 1.2.4
8
  Author URI: https://www.json-content-importer.com
9
  Text Domain: wp-memory-usage
10
  Domain Path: /languages/
@@ -23,13 +23,31 @@ defined('ABSPATH') OR exit;
23
 
24
  if ( is_admin() ) {
25
 
26
- define( 'WPMEMORYUSAGEVERSION', '1.2.4' ); // current version number
27
 
28
  function wp_memory_usage_i18n_init() {
29
  $pd = dirname(
30
  plugin_basename(__FILE__)
31
  ).'/languages/';
32
- load_plugin_textdomain('wp_memory_usage', false, $pd);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
33
  }
34
  add_action('plugins_loaded', 'wp_memory_usage_i18n_init');
35
 
@@ -38,14 +56,13 @@ if ( is_admin() ) {
38
  private $servername = "";
39
  private $memory = array();
40
 
41
- public function wp_memory_usage() {
42
- return $this->__construct();
43
- }
44
-
45
  public function __construct() {
46
  $this->get_ip_adress();
47
  add_action( 'init', array (&$this, 'check_limit') );
48
  add_action( 'wp_dashboard_setup', array (&$this, 'add_dashboard') );
 
 
 
49
  add_filter( 'admin_footer_text', array (&$this, 'add_footer') );
50
  }
51
 
@@ -135,7 +152,8 @@ if ( is_admin() ) {
135
  }
136
 
137
  public function add_dashboard() {
138
- wp_add_dashboard_widget( 'wp_memory_dashboard', __('Memory Overview', 'wp_memory_usage'), array (&$this, 'dashboard_output') );
 
139
  }
140
 
141
  private function formatWP_MEMORY_LIMIT($valin) { #WP_MEMORY_LIMIT and WP_MAX_MEMORY_LIMIT come with size and unity
4
  Plugin URI: https://www.json-content-importer.com
5
  Description: Show up memory limits, current memory usage, IP-Address, PHP-Version in the dashboard and admin footer
6
  Author: Bernhard Kux
7
+ Version: 1.2.5
8
  Author URI: https://www.json-content-importer.com
9
  Text Domain: wp-memory-usage
10
  Domain Path: /languages/
23
 
24
  if ( is_admin() ) {
25
 
26
+ define( 'WPMEMORYUSAGEVERSION', '1.2.5' ); // current version number
27
 
28
  function wp_memory_usage_i18n_init() {
29
  $pd = dirname(
30
  plugin_basename(__FILE__)
31
  ).'/languages/';
32
+
33
+ $id = "wp-memory-usage";
34
+
35
+ # $loaderrorlevel = load_plugin_textdomain('wp-memory-usage', false, $pd);
36
+ $loaderrorlevel = load_plugin_textdomain($id, false, $pd);
37
+
38
+ $mof = WP_PLUGIN_DIR."/$pd/$id"."_de_DE.mo";
39
+ if (file_exists($mof)) {
40
+
41
+ } else {
42
+
43
+ }
44
+
45
+ if ($loaderrorlevel) {
46
+
47
+ } else {
48
+
49
+ }
50
+
51
  }
52
  add_action('plugins_loaded', 'wp_memory_usage_i18n_init');
53
 
56
  private $servername = "";
57
  private $memory = array();
58
 
 
 
 
 
59
  public function __construct() {
60
  $this->get_ip_adress();
61
  add_action( 'init', array (&$this, 'check_limit') );
62
  add_action( 'wp_dashboard_setup', array (&$this, 'add_dashboard') );
63
+ if ( is_multisite() ) {
64
+ add_action( 'wp_network_dashboard_setup', array (&$this, 'add_dashboard') );
65
+ }
66
  add_filter( 'admin_footer_text', array (&$this, 'add_footer') );
67
  }
68
 
152
  }
153
 
154
  public function add_dashboard() {
155
+ $servertime = date("j.M Y, H:i:s");
156
+ wp_add_dashboard_widget( 'wp_memory_dashboard', __('Memory Overview', 'wp_memory_usage')." / ".__('Servertime', 'wp_memory_usage').": ".$servertime, array (&$this, 'dashboard_output') );
157
  }
158
 
159
  private function formatWP_MEMORY_LIMIT($valin) { #WP_MEMORY_LIMIT and WP_MAX_MEMORY_LIMIT come with size and unity