guyjusthere
09-02-2007, 10:14 PM
i need to mix up two arrays...
on is phone #'s generated from txt
the other is email adresses.. (I need to sms/email message phone numbers to all carriers since i don't know which phone service they have...)
// read the list of emails from the file.
$email_list = file("../_private/maillist.txt");
// count how many emails there are.
$total_emails = count($email_list);
// go through the list and trim off the newline character.
for ($counter=0; $counter<$total_emails; $counter++) {
$email_list[$counter] = trim($email_list[$counter]);
}
// implode the list into a single variable, put commas in, apply as $to value.
$sms = array("@message.alltel.com","bellsouth.cl","csouth1.com","@mobile.celloneusa.com","@mycellone.com","@mobile.mycingular.com","@imcingular.com","@mobile.mycingular.com","mymetropcs.com","@messaging.nextel.com","messaging.sprintpcs.com","@sprintpcs.com","@tmomail.net","@tmail.com","@myairmail.com","@vmobl.com");
//if ( mail($to,$subject,$message) ) {
// echo "The email has been sent!";
// } else {
// echo "The email has failed!";
// }
how do i mix $sms with $email_list so each number gets added to EACH E-mail...
example:
$poo = [ 1 , 2 , 3 ]
$ass = [ a , b , c ]
now mix them and i need
****$IWANT = [ 1a , 1b, 1c , 2a , 2b , 2c, 3a , 3b , 3c ]***
on is phone #'s generated from txt
the other is email adresses.. (I need to sms/email message phone numbers to all carriers since i don't know which phone service they have...)
// read the list of emails from the file.
$email_list = file("../_private/maillist.txt");
// count how many emails there are.
$total_emails = count($email_list);
// go through the list and trim off the newline character.
for ($counter=0; $counter<$total_emails; $counter++) {
$email_list[$counter] = trim($email_list[$counter]);
}
// implode the list into a single variable, put commas in, apply as $to value.
$sms = array("@message.alltel.com","bellsouth.cl","csouth1.com","@mobile.celloneusa.com","@mycellone.com","@mobile.mycingular.com","@imcingular.com","@mobile.mycingular.com","mymetropcs.com","@messaging.nextel.com","messaging.sprintpcs.com","@sprintpcs.com","@tmomail.net","@tmail.com","@myairmail.com","@vmobl.com");
//if ( mail($to,$subject,$message) ) {
// echo "The email has been sent!";
// } else {
// echo "The email has failed!";
// }
how do i mix $sms with $email_list so each number gets added to EACH E-mail...
example:
$poo = [ 1 , 2 , 3 ]
$ass = [ a , b , c ]
now mix them and i need
****$IWANT = [ 1a , 1b, 1c , 2a , 2b , 2c, 3a , 3b , 3c ]***