go to bug id or search bugs for
Consider the code below, with error_repoting set to
E_ALL (2047) before the script start:
$prev = error_reporting();
$new = error_reporting();
echo $prev . " -> " . $new;
This would set the error_reporting to 2046,
as returned and injected to the $new variable.
BUT phpinfo() will present 2047 as the local
value, instead of 2046. If you uncomment the
ini_set() call, you get the correct 2046 in the
phpindo() output. So error_repoting(..) and
ini_set("error_reporting"..) are not the same ;((
Add a Patch
Add a Pull Request
I have not tested this with ini_get, but IMHO
a) error_reporting() should be an alias for
b) error_reporting(E_ALL) should be an alias for
This bug has been fixed in CVS.
In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at http://snaps.php.net/.
In case this was a documentation problem, the fix will show up soon at
In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites in short time.
Thank you for the report, and for helping us make PHP better.