note 76851 added to function.array-combine
| From: | robertark at gmail dot com | Date: | Thu, 02 Aug 2007 11:43:34 +0000 |
| Subject: | note 76851 added to function.array-combine | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-129122@lists.php.net to get a copy of this message | ||
All of those 'array_combine' emulators did -not- work for me, so I created one of my own,
out randomly, and it worked for me, maybe you can give it a shot and let me know how it works.
Thanks..
function array_combine($arr1, $arr2)
{
$buffer = array();
foreach($arr1 as $key1 => $arr_1)
{
foreach($arr2 as $key2 => $arr_2)
$buffer[$arr_1] = $arr_2;
}
return $buffer;
}
----
Server IP: 208.69.120.35
Probable Submitter: 69.29.100.43
----
Manual Page -- http://www.php.net/manual/en/function.array-combine.php
Edit -- https://master.php.net/note/edit/76851
Del: integrated -- https://master.php.net/note/delete/76851/integrated
Del: useless -- https://master.php.net/note/delete/76851/useless
Del: bad code -- https://master.php.net/note/delete/76851/bad+code
Del: spam -- https://master.php.net/note/delete/76851/spam
Del: non-english -- https://master.php.net/note/delete/76851/non-english
Del: in docs -- https://master.php.net/note/delete/76851/in+docs
Del: other reasons-- https://master.php.net/note/delete/76851
Reject -- https://master.php.net/note/reject/76851
Search -- https://master.php.net/manage/user-notes.php