par
Invité » 20 févr. 2008, 19:36
merci bcp, très intéresant ce truc sur pear.
Sinon pour ceux que ça intéresse, j'ai aussi trouvé ça pour php4
function array_combine($arr1,$arr2) {
$out = array();
foreach($arr1 as $key1 => $value1) {
$out[$value1] = $arr2[$key1];
}
return $out;
}
merci bcp, très intéresant ce truc sur pear.
Sinon pour ceux que ça intéresse, j'ai aussi trouvé ça pour php4
[php]
function array_combine($arr1,$arr2) {
$out = array();
foreach($arr1 as $key1 => $value1) {
$out[$value1] = $arr2[$key1];
}
return $out;
}
[/php]