|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2001-09-14 19:35 UTC] jeroen@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Nov 18 10:00:02 2025 UTC |
michael@zaphod:~>php <? $a = array(array(1, "a"), array(2, "b"), array(3, "c")); $b = array(array(1, "a"), array(2, "b"), array(4, "d")); $c = array_intersect($a, $b); var_dump($c); ?> X-Powered-By: PHP/4.0.6 Content-type: text/html array(3) { [0]=> array(2) { [0]=> int(1) [1]=> string(1) "a" } [1]=> array(2) { [0]=> int(2) [1]=> string(1) "b" } [2]=> array(2) { [0]=> int(3) [1]=> string(1) "c" } } The same thing happens in 4.0.5. For comparison 4.0.4pl1-Output (and as I expect it to be): X-Powered-By: PHP/4.0.4pl1 Content-type: text/html array(2) { [0]=> array(2) { [0]=> int(1) [1]=> string(1) "a" } [1]=> array(2) { [0]=> int(2) [1]=> string(1) "b" } }