WP-CLI Error: PHP Deprecated: implode(): Passing glue string after array is deprecated.

I use WP-CLI to maintain my WordPress sites. It’s simple, it handy, and it works without any issues.

For example, I can updates all my plugins and themes (if updates are available) by executing wp theme update --all and wp plugin update --all. If WordPress core engine is available, I only need to run wp core update.

But there is a problem when I update WordPress plugins recently. Running wp plugin update --all to update all available plugin updates give me an error:

PHP Notice:  Trying to access array offset on value of type null in phar:///usr/local/bin/wp/vendor/wp-cli/extension-command/src/Plugin_Command.php on line 663
Notice: Trying to access array offset on value of type null in phar:///usr/local/bin/wp/vendor/wp-cli/extension-command/src/Plugin_Command.php on line 663

But, all updatable plugins were updated successfully. I tried to find the solutions, but I found nothing. I also try to use the nightly version via wp update --nightly, but still no luck.

Here are my wp --info

OS: Linux 5.4.0-42-generic #46-Ubuntu SMP Fri Jul 10 00:24:02 UTC 2020 x86_64
Shell: /bin/bash
PHP binary: /usr/bin/php7.4
PHP version: 7.4.3
php.ini used: /etc/php/7.4/cli/php.ini
MySQL binary: /usr/bin/mysql
MySQL version: mysql Ver 8.0.21-0ubuntu0.20.04.4 for Linux on x86_64 ((Ubuntu))
SQL modes:
WP-CLI root dir: phar://wp-cli.phar/vendor/wp-cli/wp-cli
WP-CLI vendor dir: phar://wp-cli.phar/vendor
WP_CLI phar path: /home/path/to/my/directory/
WP-CLI packages dir:
WP-CLI global config:
WP-CLI project config:
WP-CLI version: 2.5.0-alpha-068c252

WordPress Plugins Search and Comment Threading

Finally, WordPress now offers a better search engine for its plugin directory. It is using Sphinx right now. But, it does not search plugins by authors and tags. It only reads all information from readme.txt file which is delivered in every plugins uploaded to directory.

Another improvement — well, I think I should call it “feature” — is that WordPress.com is now supporting comment threading feature. This feature is included in the core if you’re using self-hosted WordPress 2.7.1. Since WordPress.com seems already upgrade to the latest version, we can now use this feature also. Just go to Settings and choose Discussion from your WordPress.com dashboard.

New design for this blog

I have been very busy in the last few weeks, many things to do. I needed to recharge my energy. And this is the result: a new design for my blog. I created this theme for fun, at least to keep my mood in balance, to bring my mood back to the other design work.
After upgrading to WordPress 2.7 few days ago, I wanted to have some changes here, especially by taking advantages from new features introduced in the latest WordPress, e.g. built-in threaded comment. Here are some notes on my new blog design.

Template tags

Still related to template tags, I try to take advantage from the way WordPress produces CSS selectors. Here is an example. Open index.php in default theme folder, you should see this for the entry loop:

<div <?php post_class() ?> id="post-<?php the_ID(); ?>">

The code above will produce something like this:
<div class="post hentry category-services category-sites category-www category-webdev tag-htaccess tag-facebook tag-linkedin tag-service tag-twitter tag-url" id="post-1026">
Do you see the pattern? It will produce some post classes on the entry data (categories and tags). This function is called post_class(). By this, we can customize how each entry (inside the loop) should be displayed, just work with the stylesheet.
If you want to make you theme compatible well with WordPress 2.7, just head to Migrating Plugins and Themes to 2.7 article at WordPress Codex. There are some other useful information for theme designers — and also for you as bloggers.

Plugin Installation in WordPress 2.7

Currently, it’s easy to upgrade WordPress plugins from the dashboard for WordPress 2.5+ version. Compared to the old method, it’s much easier because we can upgrade the plugin using a single-click. Well, not a single-click, but at least you do not need to run any FTP software.

In the coming WordPress 2.7, it’s not getting easier for users, but also for developers. There will be a page called “Install Plugins” (the name might change). Here, we have a page displaying many related sub-menus about plugins like: Search Plugins, Upload a Plugin, Featured Plugins, Popular Plugins, Newest Plugins, Recently Updated Plugins. You can figure out what they mean, right?
For example, on the “Search Plugins” page, we can search plugins available from official WordPress Plugin Directory. We can narrow our search by “terms” (or keywords), tags, and also plugin author. We can also narrow our search using tag clouds provided. The search feature will give us list of plugins with the following details: plugin name, version, rating, and description. We can directly choose to install from this page. Very easy!
What makes it even better is that we can find out more details just like when we read plugin details from WordPress Plugins Directory. If we click on the plugin table row, there will be an inline popup providing information about the mode detailed description, installation guide, FAQ and also screenshot. The bottom line is that we can have plugin information without leaving the dashboard.

'cannot yet handle MBCS in html_entity_decode' error on WP-DownloadManager

I am currently working on a WordPress-powered site. One of its features is a download section. After comparing some WordPress plugins, I decided to use Lester ‘GaMerZ’ Chan‘s WP-DownloadManager.
When I use that plugin on WordPress 2.5.1, I got an error. It’s something like this:

Warning: cannot yet handle MBCS in html_entity_decode()! in /home/.../wp-downloadmanager.php on line 308

Is it a bug? It seems that I got this error message because this plugin needs PHP 5 (I still use PHP 4). Since many hosts having PHP 5-enabled (even it does not always installed as the default version), it should not be that difficult to solve this issue. All I need to do is making all .php files are treated as PHP 5 files. Okey, this is a straight forward solution: add a new line in your .htaccess file. You should find it in your WordPress directory, if not, just add this line:

AddType application/x-httpd-php5 .php

And, the problem solved.
Update: Put AddType application/x-httpd-php5 .php in the first line in .htaccess file. Here is mine:

AddHandler application/x-httpd-php5 .php
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress

After that, create a new php file e.g. myphpinfo.php and include this line:

<?php phpinfo(); ?>

This will display about PHP version (affected by .htaccess).