Ok Here is what I have so far :
$query = "SELECT email FROM letter where state='1'";
$adminEmail=getSetting("adm_mail");
$get_results = mysql_query($query);
if ($row = mysql_fetch_array($get_results)) {
do {
sendHTMLmail($adminEmail,$row[email],$title,$message);
flush();
$timeout=300;
}
while($row = mysql_fetch_array($get_results)); }
$msg="Mailing Was A Success";
}
Which still times out the browser, but if I do this :
$query = "SELECT email FROM letter where state='1'";
$adminEmail=getSetting("adm_mail");
$get_results = mysql_query($query);
if ($row = mysql_fetch_array($get_results)) {
do {
sendHTMLmail($adminEmail,$row[email],$title,$message);
print $email . "".$row[email]." sent<br>";
flush();
$timeout=300;
}
while($row = mysql_fetch_array($get_results)); }
$msg="Mailing Was A Success";
}
Which all I added was this :
print $email . "".$row[email]." sent<br>";
It seems not to time out, but I have that printing and I dont want it to print that..
Someone out there must have a solution for me other then something really hard.
Maybe a mailer that is easy to configure or something, cause I have tried everything and been on so many post.
OR somehow put it in batches or something...
So please if you have a script or good example would be great..