in my MySQL database, each row has an email address and I'd like to send an message to each of those emails. right now i just have:
mail("email1@this.com","$subject","$message","$from");
mail("email2@this.com","$subject","$message","$from");
mail("email3@this.com","$subject","$message","$from");
etc. The problem is theres nearly 100 mail() functions for each email address. here's what i have thus far.
$query = "select email from emails";
$result = mysql_query($query);
while ($row = mysql_fetch_assoc($result))
{
mail("$row","$subject","$message","$from");
}
is there a way to put each email into a mail() function that sends an email to each address?
~JOSH