note 88935 modified in errorfunc.constants by danbrown

From: Date: Sat, 14 Feb 2009 04:07:52 +0000
Subject: note 88935 modified in errorfunc.constants by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-150646@lists.php.net to get a copy of this message
this code can tell what E_ALL includes on your PHP platform: <?php $arrayErrorLevelName = array( 'E_ERROR', 'E_WARNING', 'E_PARSE', 'E_NOTICE', 'E_CORE_ERROR', 'E_CORE_WARNING', 'E_COMPILE_ERROR', 'E_COMPILE_WARNING', 'E_USER_ERROR', 'E_USER_WARNING', 'E_USER_NOTICE', 'E_STRICT', 'E_RECOVERABLE_ERROR', 'E_DEPRECATED', 'E_USER_DEPRECATED' ); echo "<pre>On PHP " . phpversion() . "\nE_ALL includes\n--------------\n";; foreach ($arrayErrorLevelName as $errorLevelName) { eval("if ($errorLevelName & E_ALL) echo(\"$errorLevelName\n\");"); } ?> --was-- this code can tell what E_ALL includes on your PHP platform: $arrayErrorLevelName = array( 'E_ERROR', 'E_WARNING', 'E_PARSE', 'E_NOTICE', 'E_CORE_ERROR', 'E_CORE_WARNING', 'E_COMPILE_ERROR', 'E_COMPILE_WARNING', 'E_USER_ERROR', 'E_USER_WARNING', 'E_USER_NOTICE', 'E_STRICT', 'E_RECOVERABLE_ERROR', 'E_DEPRECATED', 'E_USER_DEPRECATED' ); echo "<pre>On PHP " . phpversion() . "\nE_ALL includes\n--------------\n";; foreach ($arrayErrorLevelName as $errorLevelName) { eval("if ($errorLevelName & E_ALL) echo(\"$errorLevelName\n\");"); } http://php.net/manual/en/errorfunc.constants.php

« previous php.notes (#150646) next »