Fixed a couple more typos.

Fixed one bad example.


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@132359 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Torben Wilson 2003-06-18 18:19:07 +00:00
parent 7c4099cc62
commit 50d662366f

View file

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.116 $ -->
<!-- $Revision: 1.117 $ -->
<chapter id="language.types">
<title>Types</title>
@ -1862,7 +1862,7 @@ Array
<![CDATA[
// fill an array with all items from a directory
$handle = opendir('.');
while ($file = readdir($handle)) {
while (false !== ($file = readdir($handle))) {
$files[] = $file;
}
closedir($handle);
@ -1872,7 +1872,7 @@ closedir($handle);
</example>
<para>
Arrays are ordered. You can also change the order using various
sorting-functions. See the <link linkend="ref.array">array
sorting functions. See the <link linkend="ref.array">array
functions</link> section for more information. You can count
the number of items in an array using the
<function>count</function> function.
@ -1927,7 +1927,7 @@ $juices["apple"]["green"] = "good";
</programlisting>
</example>
<para>
You should be aware, that array assignment always involves
You should be aware that array assignment always involves
value copying. You need to use the reference operator to copy
an array by reference.
<informalexample>
@ -1937,7 +1937,7 @@ $juices["apple"]["green"] = "good";
$arr1 = array(2, 3);
$arr2 = $arr1;
$arr2[] = 4; // $arr2 is changed,
// $arr1 is still array(2,3)
// $arr1 is still array(2, 3)
$arr3 = &$arr1;
$arr3[] = 4; // now $arr1 and $arr3 are the same