PHP.nl

debug_print_backtrace

debug_print_backtrace

Prints a backtrace

void **debug_print_backtrace** int $options int $limit
  prints a PHP backtrace. It
 prints the function calls, d/d files and
 ed stuff.
`debug_print_backtrace``include``require``eval`

optionsThis parameter is a bitmask for the following options:

limit This parameter can be used to limit the number of stack frames printed. By default (=) it prints all stack frames. limit``0

return.void

Voorbeeld: example

<?php
// include.php file

function a() {
    b();
}

function b() {
    c();
}

function c(){
    debug_print_backtrace();
}

a();

?>
<?php
// test.php file
// this is the file you should run

include 'include.php';
?>
#0  c() called at [/tmp/include.php:10]
#1  b() called at [/tmp/include.php:6]
#2  a() called at [/tmp/include.php:17]
#3  include(/tmp/include.php) called at [/tmp/test.php:3]

debug_backtrace