#19920 [Opn->Bgs]: Not a bug, but an add-on...

From: Date: Wed, 16 Oct 2002 03:39:47 +0000
Subject: #19920 [Opn->Bgs]: Not a bug, but an add-on...
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-22531@lists.php.net to get a copy of this message
 ID:               19920
 Updated by:       sniper@php.net
 Reported By:      meggleston@matrixreg.com
-Status:           Open
+Status:           Bogus
 Bug Type:         Feature/Change Request
 Operating System: RedHat Linux 7.2
 PHP Version:      4.2.0
 New Comment:

Add this kind of comments to the manual.



Previous Comments:
------------------------------------------------------------------------

[2002-10-15 14:15:42] webmaster@tsn.dk

Maybe you should add it as a comment to array_search in the manual?

------------------------------------------------------------------------

[2002-10-15 12:25:14] meggleston@matrixreg.com

I have a small snippit of code that I believe people would find very
useful, however I was unsure as to where to stick it.

function array_multisearch($needle, $haystack, $strict = FALSE) {
	for ($x = 0; $x < count($haystack); $x++) {
		if (array_search($needle, $haystack[$x], $strict)) {return $x;}
	}
}

This function allows for arrays of hash-arrays kind of searching...

------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=19920&edit=1



Thread (3 messages)

« previous php.bugs (#22531) next »