I have 3 explode statements:
$emails = explode(',', $row['email']);
$firstnames = explode(',', $row['first_name']);
$lastnames = explode(',', $row['last_name']);
each explode produces three (3) arrays:
//emails
Array
(
[0] => [email protected]
[1] => [email protected]
[2] => [email protected]
[3] => [email protected]
)
//first name
Array
(
[0] => Bill
[1] => Jake
[2] => John
[3] => Bob
)
//last name
Array
(
[0] => Jones
[1] => Smith
[2] => Johnson
[3] => Bakers
)
I can get the one array easily like this: for example:
foreach ($emails as $email) {
echo $email;
}
That will echo out the emails. But I want to add $firstname and $lastname into it. for example, I want to echo:
[email protected] Bill Jones
how can i do it?