cvs: phpdoc /en/reference/array/functions end.xml
| From: | Philip Olson | Date: | Thu, 18 Apr 2002 23:29:24 +0000 |
| Subject: | cvs: phpdoc /en/reference/array/functions end.xml | ||
| Groups: | php.doc | ||
| Request: | Send a blank email to phpdoc+get-969344560@lists.php.net to get a copy of this message | ||
philip Thu Apr 18 19:29:24 2002 EDT
Modified files:
/phpdoc/en/reference/array/functions end.xml
Log:
end(): Added a simple example using end()
Index: phpdoc/en/reference/array/functions/end.xml
diff -u phpdoc/en/reference/array/functions/end.xml:1.2
phpdoc/en/reference/array/functions/end.xml:1.3
--- phpdoc/en/reference/array/functions/end.xml:1.2 Wed Apr 17 02:36:30 2002
+++ phpdoc/en/reference/array/functions/end.xml Thu Apr 18 19:29:24 2002
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.2 $ -->
+<!-- $Revision: 1.3 $ -->
<!-- splitted from ./en/functions/array.xml, last change in rev 1.2 -->
<refentry id="function.end">
<refnamediv>
@@ -17,6 +17,22 @@
<para>
<function>end</function> advances <parameter>array</parameter>'s
internal pointer to the last element, and returns that element.
+ </para>
+ <para>
+ <example>
+ <title>A simple <function>end</function> example</title>
+ <programlisting role="php">
+<![CDATA[
+<?php
+
+ $fruits = array('apple','banana','cranberry');
+
+ print end($fruits); // cranberry
+
+?>
+]]>
+ </programlisting>
+ </example>
</para>
<para>
See also <function>current</function>,