nlopess         Sat Nov 13 12:58:53 2004 EDT

  Modified files:              
    /phpdoc/en/reference/errorfunc/functions    debug-print-backtrace.xml 
  Log:
  adding docs and example
  
http://cvs.php.net/diff.php/phpdoc/en/reference/errorfunc/functions/debug-print-backtrace.xml?r1=1.2&r2=1.3&ty=u
Index: phpdoc/en/reference/errorfunc/functions/debug-print-backtrace.xml
diff -u phpdoc/en/reference/errorfunc/functions/debug-print-backtrace.xml:1.2 
phpdoc/en/reference/errorfunc/functions/debug-print-backtrace.xml:1.3
--- phpdoc/en/reference/errorfunc/functions/debug-print-backtrace.xml:1.2       
Mon Nov  1 11:31:23 2004
+++ phpdoc/en/reference/errorfunc/functions/debug-print-backtrace.xml   Sat Nov 
13 12:58:53 2004
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.2 $ -->
+<!-- $Revision: 1.3 $ -->
   <refentry id="function.debug-print-backtrace">
    <refnamediv>
     <refname>debug_print_backtrace</refname>
@@ -14,16 +14,88 @@
       <void/>
      </methodsynopsis>
     <para>
-     <function>debug_print_backtrace</function> prints a PHP backtrace.
+     <function>debug_print_backtrace</function> prints a PHP backtrace. It
+     prints the function calls, included/required files and
+     <function>eval</function>ed stuff.
     </para>
-    
-    &warn.undocumented.func;
-    
+   </refsect1>
+
+   <refsect1 role="parameters">
+    &reftitle.parameters;
     <para>
-     See also <function>debug_backtrace</function>.
+     This function has no parameters.
     </para>
    </refsect1>
-  </refentry>
+
+   <refsect1 role="returnvalues">
+    &reftitle.returnvalues;
+    <para>
+     &return.void;
+    </para>
+   </refsect1>
+
+   
+   <refsect1 role="examples">
+    &reftitle.examples;
+    <para>
+    <example>
+     <title><function>debug_print_backtrace</function> example</title>
+     <programlisting role="php">
+<![CDATA[
+<?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';
+?>
+]]>
+     </programlisting>
+     &example.outputs.similar;
+     <screen>
+<![CDATA[
+#0  eval() called at [/tmp/include.php:5]
+#1  a() called at [/tmp/include.php:17]
+#2  include(/tmp/include.php) called at [/tmp/test.php:3]
+
+#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]
+]]>
+     </screen>
+    </example>
+   </para>
+  </refsect1>
+
+  <refsect1 role="seealso">
+   &reftitle.seealso;
+   <para>
+    <simplelist>
+     <member><function>debug_backtrace</function></member>
+    </simplelist>
+   </para>
+  </refsect1>
+ </refentry>
 
 <!-- Keep this comment at the end of the file
 Local variables:

Reply via email to