note 92922 added to function.debug-backtrace
| From: | tracefromsomewheredotsk at osu1 dot php dot net | Date: | Fri, 14 Aug 2009 20:03:31 +0000 |
| Subject: | note 92922 added to function.debug-backtrace | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-159494@lists.php.net to get a copy of this message | ||
i'm not sure what the "provide_object" flag should do - i've tried both, but no
difference, maybe i've misunderstood something, but...
<?php
...
$backtraces = debug_backtrace(true);
print_r($backtraces);
?>
prints out:
Array ( [0] => Array ( [file] => /home/trace/Documents/projects/engine/core/database.php
[line] => 370 [function] => write [class] => log [object] => log Object (
[logging:private] => 1 [to_browser:private] => 1 [log_engine:private] => ) [type] =>
-> [args] => Array ( [0] => debug [1] => query(#4): SELECT * FROM sessions WHERE
id = 'abc' ) ) [1] => Array ( [file] =>
/home/trace/Documents/projects/engine/index.php [line] => 86 [function] => query [class] =>
database [object] => database Object ( [databases:private] => Array ( [__r] => Array ( [0]
=> Array ( [host] => localhost [username] => root [password] => root [database] =>
test [port] => 3306 [weight] => 1 ) ) [__w] => Array ( [0] => Array ( [host] =>
localhost [username] => root [password] => root [database] => test [port] => 3306
[weight] => 1 ) ) ) [excluded:private] => Array ( ) [rlink:private] => mysqli Object ( )
[wlink:private] => mysqli Object ( ) [query:private] => SELECT * FROM sessions WHERE
id = 'abc' [query_count:private] => 4 [query_debug:private] => 1
[query_error:private] => [result:private] => mysqli_result Object ( ) ) [type] => ->
[args] => Array ( [0] => SELECT * FROM sessions WHERE id = 'abc' ) ) )
, while...
<?php
...
$backtraces = debug_backtrace(false);
print_r($backtraces);
?>
just prints out the same. just thought, that the provide_object = false, removes the all [object]
hash/assoc keys from the output. if i misunderstood something sorry for spam.
-trace
----
Server IP: 217.73.17.12
Probable Submitter: 89.173.71.168
----
Manual Page -- http://www.php.net/manual/en/function.debug-backtrace.php
Edit -- https://master.php.net/note/edit/92922
Del: integrated -- https://master.php.net/note/delete/92922/integrated
Del: useless -- https://master.php.net/note/delete/92922/useless
Del: bad code -- https://master.php.net/note/delete/92922/bad+code
Del: spam -- https://master.php.net/note/delete/92922/spam
Del: non-english -- https://master.php.net/note/delete/92922/non-english
Del: in docs -- https://master.php.net/note/delete/92922/in+docs
Del: other reasons-- https://master.php.net/note/delete/92922
Reject -- https://master.php.net/note/reject/92922
Search -- https://master.php.net/manage/user-notes.php