sean Mon Feb 23 21:22:26 2004 EDT
Modified files:
/phpdoc/en/reference/exec/functions exec.xml
Log:
Added a simple example (could use more, but at least it has one now)
http://cvs.php.net/diff.php/phpdoc/en/reference/exec/functions/exec.xml?r1=1.10&r2=1.11&ty=u
Index: phpdoc/en/reference/exec/functions/exec.xml
diff -u phpdoc/en/reference/exec/functions/exec.xml:1.10
phpdoc/en/reference/exec/functions/exec.xml:1.11
--- phpdoc/en/reference/exec/functions/exec.xml:1.10 Tue Feb 17 21:51:09 2004
+++ phpdoc/en/reference/exec/functions/exec.xml Mon Feb 23 21:22:26 2004
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.10 $ -->
+<!-- $Revision: 1.11 $ -->
<!-- splitted from ./en/functions/exec.xml, last change in rev 1.2 -->
<refentry id="function.exec">
<refnamediv>
@@ -39,6 +39,20 @@
return status of the executed command will be written to this
variable.
</para>
+ <para>
+ <example>
+ <title>An <function>exec</function> example</title>
+ <programlisting role="php">
+<![CDATA[
+<?php
+// outputs the username that owns the running php/httpd process
+// (on a system with the "whoami" executable in the path)
+echo exec('whoami');
+?>
+]]>
+ </programlisting>
+ </example>
+ </para>
&warn.escapeshell;
¬e.exec-bg;
¬e.exec-path;