ID: 5050
Updated by: [EMAIL PROTECTED]
Reported By: sp at alkor dot ru
-Status: Analyzed
+Status: Bogus
Bug Type: Feature/Change Request
Operating System: FreeBSD 4.0-R/3.x-R
PHP Version: 4.0.0 Release
New Comment:
ini_set("track_errors", 1);
Or use error_get_last()
Previous Comments:
------------------------------------------------------------------------
[2000-08-04 18:00:52] [EMAIL PROTECTED]
Andi says it is an intended behaviour, so reclassifying is as a feature
request.
------------------------------------------------------------------------
[2000-07-23 14:59:26] stas at cvs dot php dot net
The problem here is that php_error_cb sets $php_errormsg in active
symbol table (i.e., of calling function) and not in the global symbol
table. I do not know why. Anybody does?
------------------------------------------------------------------------
[2000-06-15 05:16:10] sp at alkor dot ru
# in apache.conf: php_value track_errors on
# This problem seems exists in PHP 3.0.x too.
function boo($tag) {
global $php_errormsg;
echo("$tag: $php_errormsg<br><br>\n");
}
function bar() {
$x = @fopen("file-no-such", "r", 0);
if(!$x) boo("BAR");
}
$php_errormsg = "Croak!";
$foo = @fopen("no-such-file", "r", 0);
if(!$foo) boo("MAIN");
$php_errormsg = "Croak!"; bar();
# Request: is it possible make something like
# set_track_errors(bool) to change track_errors
# on fly.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=5050&edit=1