$array1 = array("apple", "orange", "banana");
$array2 = array("juice", "ade", "flavour");
$array3 = array();
$array2value = "";
foreach ($array1 as $key => &$value) {
$array2value = $array2[$key];
array_push($array3, $value . $array2value);
}
echo "<pre>";
print_r($array3);
echo "</pre>";
Array
(
[0] => applejuice
[1] => orangeade
[2] => bananaflavour
)
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.