This is what I am planing to do with my email table . I have setup Postfix on same server .
Separate email column into two columns for example
user@gmail.com
get separated into
Username | Hostname
|
user | gmail.com
Now fetching data from database I do sql query order by hostname
foreach($rows as $row)
{
$data[$row['hostname']][] = $row['username'] . '@' . $row['hostname'];
}
foreach($data as $hostname => $emails)
{
$list = implode(',',$emails);
mail($list,'This is subject','Some message');
}
Will doing this save me from pinging each server (like yahoo,google) multiple times ?