PHP debug_print_backtrace() 函数

PHP 教程 · 2019-01-24 14:28:04

定义和用法

debug_print_backtrace() 函数打印 backtrace。

该函数显示由 debug_print_backtrace() 函数代码生成的数据。

语法


debug_print_backtrace()


实例


<?php
function one($str1, $str2)
  {
  two("Glenn", "Quagmire");
  }
function two($str1, $str2)
  {
  three("Cleveland", "Brown");
  }
function three($str1, $str2)
  {
  debug_print_backtrace();
  }
one("Peter", "Griffin");
?>

上面代码的输出如下所示:


#0 three(Cleveland, Brown) called at [C:webfoldertest.php:8]
#1 two(Glenn, Quagmire) called at [C:webfoldertest.php:4]
#2 one(Peter, Griffin) called at [C:webfoldertest.php:15]


点击查看所有 PHP 教程 文章: https://codercto.com/courses/l/5.html

查看所有标签

Hatching Twitter

Hatching Twitter

Nick Bilton / Portfolio Hardcover / 2013-11-5 / USD 28.95

The dramatic, unlikely story behind the founding of Twitter, by New York Times bestselling author and Vanity Fair special correspondent The San Francisco-based technology company Twitter has become......一起来看看 《Hatching Twitter》 这本书的介绍吧!

JSON 在线解析
JSON 在线解析

在线 JSON 格式化工具

HTML 编码/解码
HTML 编码/解码

HTML 编码/解码

XML、JSON 在线转换
XML、JSON 在线转换

在线XML、JSON转换工具