davey           Tue Jun 17 19:02:06 2003 EDT

  Modified files:              
    /phpdoc/en/reference/funchand/functions     register-tick-function.xml 
  Log:
  added example and documentated using an object->method as the callback
  
Index: phpdoc/en/reference/funchand/functions/register-tick-function.xml
diff -u phpdoc/en/reference/funchand/functions/register-tick-function.xml:1.3 
phpdoc/en/reference/funchand/functions/register-tick-function.xml:1.4
--- phpdoc/en/reference/funchand/functions/register-tick-function.xml:1.3       Sat 
Oct 26 16:40:42 2002
+++ phpdoc/en/reference/funchand/functions/register-tick-function.xml   Tue Jun 17 
19:02:06 2003
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.3 $ -->
+<!-- $Revision: 1.4 $ -->
 <!-- splitted from ./en/functions/funchand.xml, last change in rev 1.12 -->
   <refentry id="function.register-tick-function">
    <refnamediv>
@@ -19,7 +19,26 @@
      Registers the function named by <parameter>func</parameter> to be
      executed when a <link
      linkend="control-structures.declare">tick</link> is
-     called.</simpara>
+     called.
+    </simpara>
+    <simpara>
+     You may also pass an array consisting of an object and a method as the 
<parameter>func</parameter>
+    </simpara>
+    <example>
+     <title><function>register_tick_function</function> Example</title>
+     <programlisting role="php">
+<![CDATA[
+<?php
+// using a function as the callback
+register_tick_function('myFunction',TRUE);
+
+// using an object-&gt;method
+$object = new myClass();
+register_tick_function(array(&amp;$object,'myMethod'),TRUE);
+?>
+]]>
+     </programlisting>
+    </example>
    </refsect1>
   </refentry>
 



-- 
PHP Documentation Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to