Funkce PHP debug_print_backtrace().
Příklad
Vytiskněte PHP backtrace:
<?php
function a($txt) {
b("Glenn");
}
function b($txt) {
c("Cleveland");
}
function c($txt) {
debug_print_backtrace();
}
a("Peter");
?>
Definice a použití
Funkce debug_print_backtrace() vytiskne PHP backtrace.
Tato funkce zobrazuje data z kódu, který vedl k funkci debug_print_backtrace().
Syntax
debug_print_backtrace(options, limit);
Hodnoty parametrů
Parameter | Description |
---|---|
options | Optional. Specifies a bitmask for the following option: DEBUG_BACKTRACE_IGNORE_ARGS (Whether or not to omit the "args" index, and all the function/method arguments, to save memory) |
limit | Optional. Limits the number of stack frames printed. By default (limit=0) it prints all stack frames |
Technické údaje
Návratová hodnota: | Žádný |
---|---|
Verze PHP: | 5,0+ |
PHP Changelog: | PHP 5.4: Byl přidán limit volitelných parametrů PHP 5.3.6: Byly přidány možnosti volitelných parametrů |
Odkaz na chyby PHP