PHP

Use of undefined constant STDOUT – assumed ‘STDOUT’ (this will throw an Error in a future version of PHP)

Error from loading CLI script in Web Use of undefined constant STDOUT – assumed ‘STDOUT’ (this will throw an Error in a future version of PHP) Solution if(!defined(‘STDIN’)) define(‘STDIN’, fopen(‘php://stdin’, ‘rb’)); if(!defined(‘STDOUT’)) define(‘STDOUT’, fopen(‘php://stdout’, ‘wb’)); if(!defined(‘STDERR’)) define(‘STDERR’, fopen(‘php://stderr’, ‘wb’));

Use of undefined constant STDOUT – assumed ‘STDOUT’ (this will throw an Error in a future version of PHP) Read More »

Installing PHP Extension in WP ENV

I need pdo_mysql php extension to use on my Wordpress plugins. After a day of research, I found out that this is the limitation of wp-env. The developers do not want us to touch more to any setting of PHP and Docker. So we have to manually install everytime after wp-env start. You can use this way to install other php extensions. Install pdo_mysql after WP-ENV started. wp-env start docker ps docker exec -it [WORDPRESS_CONTAINER_ID] docker-php-ext-install pdo_mysql docker exec -it [WORDPRESS_CONT[…]

Installing PHP Extension in WP ENV Read More »

System error ‘[security.WindMcryptCbc.encrypt] extension ‘mcrypt’ is not loaded.’.

I don’t like error, but I have to fix the error, I note down here to do reference. I’m using CentOS 7, I think cause by upgraded from PHP 5 to PHP 7. I’m using DirectAdmin. What I found from internet The mcrypt extension has been abandonware for nearly a decade now, and was also

System error ‘[security.WindMcryptCbc.encrypt] extension ‘mcrypt’ is not loaded.’. Read More »