Re: [PHP4BETA] Unique Array Values

From: Date: Thu, 27 Apr 2000 15:36:13 +0000
Subject: Re: [PHP4BETA] Unique Array Values
References: 1  Groups: php.version4 
Request: Send a blank email to php-version4+get-14077@lists.php.net to get a copy of this message
On Wed, 26 Apr 2000, Andreas Pour wrote: > > Hi, > > Well, there are many undocumented functions in PHP4 -- maybe the one I'm > looking for is lurking somewhere. I would like to retrieve all the > unique values in an array. For example, > > array_values(array("cat", "dog", "mouse", "dog")) > > would return > > array("cat", "dog", "mouse") > > If such a function does not exist, perhaps a flag to the current > array_values for "unique = true" is possible? I'm planning to write array_uniq() soon. -Andrei "Man, if you gotta ask you'll never know." - Louis Armstrong, when asked "What is jazz?"

« previous php.version4 (#14077) next »