#27459 [NEW]: Error handling page should use constants instead of raw integers
| From: | cellog@php.net | Date: | Tue, 02 Mar 2004 14:29:41 +0000 |
| Subject: | #27459 [NEW]: Error handling page should use constants instead of raw integers | ||
| Groups: | php.doc | ||
| Request: | Send a blank email to phpdoc+get-969359346@lists.php.net to get a copy of this message | ||
From: cellog@php.net
Operating system: na
PHP version: Irrelevant
PHP Bug Type: Documentation problem
Bug description: Error handling page should use constants instead of raw integers
Description:
------------
at
http://www.php.net/manual/en/ref.errorfunc.php
the example uses raw integers instead of error constants:
$errortype = array (
1 => "Error",
2 => "Warning",
4 => "Parsing Error",
8 => "Notice",
16 => "Core Error",
32 => "Core Warning",
64 => "Compile Error",
128 => "Compile Warning",
256 => "User Error",
512 => "User Warning",
1024 => "User Notice"
);
This should use E_ERROR, E_WARNING, etc. Using the raw numbers is not
best practice, and should not be encouraged.
--
Edit bug report at http://bugs.php.net/?id=27459&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=27459&r=trysnapshot4
Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=27459&r=trysnapshot5
Fixed in CVS: http://bugs.php.net/fix.php?id=27459&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=27459&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=27459&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=27459&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=27459&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=27459&r=support
Expected behavior: http://bugs.php.net/fix.php?id=27459&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=27459&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=27459&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=27459&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=27459&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=27459&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=27459&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=27459&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=27459&r=float