note 103972 added to function.array-flip
| From: | omnibus at omnibus dot edu dot pl | Date: | Sat, 14 May 2011 17:31:46 +0000 |
| Subject: | note 103972 added to function.array-flip | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-179723@lists.php.net to get a copy of this message | ||
Note that array_flip() does not work well with a non-associative array containing integers. I
thought that array(0=>1, 1=>2), built without explicit definition of keys (defined like:
$array[] = 1; $array[] = 2;), will be flipped to array(1=>0, 2=>1). Instead, I received some
warnings.
----
Server IP: 195.114.0.19
Probable Submitter: 95.40.185.212
----
Manual Page -- http://www.php.net/manual/en/function.array-flip.php
Edit -- https://master.php.net/note/edit/103972
Del: integrated -- https://master.php.net/note/delete/103972/integrated
Del: useless -- https://master.php.net/note/delete/103972/useless
Del: bad code -- https://master.php.net/note/delete/103972/bad+code
Del: spam -- https://master.php.net/note/delete/103972/spam
Del: non-english -- https://master.php.net/note/delete/103972/non-english
Del: in docs -- https://master.php.net/note/delete/103972/in+docs
Del: other reasons-- https://master.php.net/note/delete/103972
Reject -- https://master.php.net/note/reject/103972
Search -- https://master.php.net/manage/user-notes.php