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

Last updated on June 22nd, 2022 at 07:15 pm

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'));

Tags:

Discover more from Juzhax Technology

Subscribe now to keep reading and get access to the full archive.

Continue reading