com web/bugs: Fix the format sent to admin_table_static( ): www/admin/index.php
| From: | Kalle Sommer Nielsen | Date: | Thu, 24 Aug 2017 15:08:48 +0000 |
| Subject: | com web/bugs: Fix the format sent to admin_table_static( ): www/admin/index.php | ||
| Groups: | php.webmaster | ||
| Request: | Send a blank email to php-webmaster+get-26343@lists.php.net to get a copy of this message | ||
Commit: d19801e5ae9da552e26a1e0a181e67cca59ca9db
Author: Kalle Sommer Nielsen <kalle@php.net> Thu, 24 Aug 2017 17:08:48 +0200
Parents: d29f322838217e6824236af8dac6c1a9852b9d08
Branches: master
Link: http://git.php.net/?p=web/bugs.git;a=commitdiff;h=d19801e5ae9da552e26a1e0a181e67cca59ca9db
Log:
Fix the format sent to admin_table_static()
Changed paths:
M www/admin/index.php
Diff:
diff --git a/www/admin/index.php b/www/admin/index.php
index 57f695e..e797624 100644
--- a/www/admin/index.php
+++ b/www/admin/index.php
@@ -96,9 +96,9 @@ if ($action === 'phpinfo') {
$rows = array();
- array_walk($row, function(&$value, $key) use($rows) {
- $rows[str_replace('cnt_', '', $key)] = $value;
- });
+ foreach($row as $key => $value) {
+ $rows[] = [str_replace('cnt_', '', $key), $value];
+ }
admin_table_static(['Table', 'Rows'], $rows);