From: [EMAIL PROTECTED] Operating system: FreeBSD 4.7 PHP version: 4.2.3 PHP Bug Type: Feature/Change Request Bug description: __PARENTFILE__ and __PARENTLINE__ constants
I'm writing a script which calls a function which handles errors. The function lies in a different file (it was included) than where the function was called. index.php --> calls function in wine.inc --> calls function in db.inc --> calls error handling function in wine.inc --> prints error nicely and exits at index.php __PARENTFILE__ would be "" and __PARENTLINE__ would be "". At wine.inc __PARENTFILE__ would be "/path/to/index.php" and __PARENTLINE__ would be the line number where we left index.php (called the function in wine.inc). At db.inc __PARENTFILE__ would be "/path/to/wine.inc" and __PARENTLINE__ would be the line number where we left wine.inc (where the function called was in db.inc). Make sense? I couldn't find ANYTHING in documentation that allowed such a view into the system. A $_EXECUTION like global would be nice too, showing at the point called which files were open (either through includes or requires or FOPENs) and the line numbers they were at at the time of calling. Or maybe this would be more proper as a function returning an array of information? -- Edit bug report at http://bugs.php.net/?id=20049&edit=1 -- Try a CVS snapshot: http://bugs.php.net/fix.php?id=20049&r=trysnapshot Fixed in CVS: http://bugs.php.net/fix.php?id=20049&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=20049&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=20049&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=20049&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=20049&r=support Expected behavior: http://bugs.php.net/fix.php?id=20049&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=20049&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=20049&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=20049&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=20049&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=20049&r=dst IIS Stability: http://bugs.php.net/fix.php?id=20049&r=isapi