mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 00:48:54 +00:00
Added note about the order of the function parameters. Docs could be miss-interpreted if, this note tries to reinforce expected behaviour and use
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@333318 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
9905374cd0
commit
7f70616b6a
1 changed files with 17 additions and 0 deletions
|
@ -149,6 +149,23 @@ Array
|
|||
<literal>array_diff_assoc($array1[0], $array2[0]);</literal>.
|
||||
</simpara>
|
||||
</note>
|
||||
<note>
|
||||
<simpara>
|
||||
Ensure you pass arguments in the correct order when comparing similar
|
||||
arrays with more keys. The new array should be the first in the list,
|
||||
for example,
|
||||
<programlisting role="php">
|
||||
<![CDATA[
|
||||
<?php
|
||||
$array1 = array('a' => 'blue', 'b' => 'green', 'c' => 'yellow');
|
||||
$array2 = array('a' => 'blue', 'b' => 'green');
|
||||
$result = array_diff_assoc($array1, $array2);
|
||||
print_r($result);
|
||||
?>
|
||||
]]>
|
||||
</programlisting>
|
||||
</simpara>
|
||||
</note>
|
||||
</refsect1>
|
||||
|
||||
<refsect1 role="seealso">
|
||||
|
|
Loading…
Reference in a new issue