From: [EMAIL PROTECTED]
Operating system: all
PHP version: 4.3.0
PHP Bug Type: Feature/Change Request
Bug description: Show the current functionname
Is it possible to create a getCurrentFunctionName() function?
If an user defined error occured (for example: you are not getting a valid
SQL-resultset with your query) in a function, it would be handy to show
the functionname where the error is generated.
Possible example:
function getQueryResultSet() {
// requested code
$currentFunctionName = getCurrentFunctionName();
$query="select * from table";
$result = mysql_query($query) or die ("The error occured in ".
$currentFunctionName);
return $result;
}
--
Edit bug report at http://bugs.php.net/?id=21515&edit=1
--
Try a CVS snapshot: http://bugs.php.net/fix.php?id=21515&r=trysnapshot
Fixed in CVS: http://bugs.php.net/fix.php?id=21515&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=21515&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=21515&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=21515&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=21515&r=support
Expected behavior: http://bugs.php.net/fix.php?id=21515&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=21515&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=21515&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=21515&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=21515&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=21515&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=21515&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=21515&r=gnused