| px | top | add code | search | signup | login | help |
<?php
/*
Name: array_merge_assoc
Author: Markus Diersbock
Details: Takes two related indexed arrays and
combines them into one associative array.
Revisions: 2003/12/13 - Created
*/
function array_merge_assoc($keyarray, $valuearray){
$i=0;
foreach($keyarray as $element){
$aryreturn[$element]=$valuearray[$i++];
}
return $aryreturn;
}
?>
Comments or questions?
PX is running PHP 5.2.11
Thanks to Miranda Productions for hosting and bandwidth.
Use of any code from PX is at your own risk.