I am trying to send emails to huge number of users (11000) and I can't send except 300 email per hour so I made that code:
$query_users = $this->db->query('SELECT * FROM `users_list` ');
foreach ($query_users->result() as $row)
{
$this->email->to($row->email);
$this->email->send();
if($row->id % 300 ==0) { sleep(3600);}
}
but I got every hour 300 spam email in my account (as I am sending from it) saying:
A message that you sent was rejected by the local scanning code that checks incoming messages on this system. The following error was given:
This message was classified as SPAM and may not be delivered
Note: when I try to send email to specific person, it's sent correctly. I don't know how to solve this issue, any help?