note 85234 deleted from function.array-flip by danbrown
| From: | danbrown@php.net | Date: | Fri, 14 May 2010 15:03:29 +0000 |
| Subject: | note 85234 deleted from function.array-flip by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-169247@lists.php.net to get a copy of this message | ||
Note Submitter: rdanner
----
using array_flip(array_flip($array)) or array_keys(array_flip($array)) as key-collapsing
alternatives to array_unique() makes your intention less apparent. Try:
array_values(array_unique($array))
as a more readable alternative.