|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2001-08-30 23:36 UTC] andrei@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Nov 20 07:00:01 2025 UTC |
I am requesting that the functions in_array and array_search support an array type for their needle arguments. This feature would allow these functions to search for an array in an array of arrays. i.e. <? $needle = array(3,4); $haystack = array( array(1,2), array(3,4), array(5,6) ); if(in_array($needle, $haystack)){ echo "Yes"; }else{ echo "No"; } ?> Outputs: Warning: Wrong datatype for first argument in call to in_array in test.phtml