A
Anonymous
Guest
I have developed a FOR construct to put a delay on my mailing list so as not to time out the server. I believe it is nearly right, but I am getting an error and for the life of me, I do not see where it is. Thaniks to any and all that take the time to look at it. Here is the code
Here is the error Line 129 is for $i = 1, $hold = 10, set_time_limit(30); $i < $hold; i++, sleep(3))
Code:
include_once ("config.php");
for ($i = 1, $hold = 10, set_time_limit(30); $i < $hold; i++, sleep(3)){
//Get emails from db_tbl List
$result = mysql_query("SELECT email FROM db_tble WHERE status = '1'");
if (!$result) {
echo 'Could not run query: ' . mysql_error();
exit;
}
else{
$row = mysql_fetch_object($result);
echo $row->email;
mail($row->email, $subject, $message, $headers);
}
}
mysql_free_result($result);
?>
Here is the error Line 129 is for $i = 1, $hold = 10, set_time_limit(30); $i < $hold; i++, sleep(3))
Code:
Parse error: parse error, unexpected T_INC, expecting ')' in /home/myacct/public_html/mailer/APEX_mime.php on line 129