how to stdout php code example
Example 1: how to debug in php
ini_set('display_errors', 'On');
error_reporting(E_ALL);
Example 2: php write to standard out
fwrite(STDOUT, 'foo');
ini_set('display_errors', 'On');
error_reporting(E_ALL);
fwrite(STDOUT, 'foo');