E-Mail Script

Admin side of my website allows me to send multiple e-mail to almost 2000 registered users. Server only allows max of 100 or 1500 e-mails per day to be sent. Need script to send out 75 e-mails an hour untill all delivered. this is the present script that needs replaced as it tries to send out all 2000 in one go and they are all returned undelivered.


# Include the DB details

require_once('../../[url removed, login to view]');

$subject = $_POST['subject'];

$messagecontent = $_POST['message'];

echo 'Sending E-mails:</br>';

# Create recordset

$colname_rsInstructors = "1";

$query_rsInstructors = sprintf("SELECT i_email, i_username, i_password FROM instructors;", $colname_rsInstructors);

$rsInstructors = mysql_query($query_rsInstructors, $conn) or die ('Could not connect to database because: ' . mysql_error());

$row_rsInstructors = mysql_fetch_assoc($rsInstructors);

$totalRows_rsInstructors = mysql_num_rows($rsInstructors);

do {

$sql = mysql_query("SELECT i_email, i_password, i_username

FROM instructors;")

or die ('Select failed because: ' . mysql_error());

# Set variables from the record set

$email = $row_rsInstructors['i_email'];

$user = $row_rsInstructors['i_username'];

$password = $row_rsInstructors['i_password'];

$messagefooter = "This E-mail has been sent to you as a registered member of the Driving Lesson Booking

Service<br />

http://www.DLBS.co.uk. <br />

To amend your details you can login at [url removed, login to view]

with the user name $user and password $password.";

$message = "$messagecontent $messagefooter";

# Send email

# @mail($email, $subject, $message, "From: ");

@mail($email, $subject, $message,

"From: [url removed, login to view] <>rnMIME-Version: 1.0rnContent-type: text/html; charset=iso-8859-1rn");

echo'E-mail sent to : '.$email. '


} while ($row_rsInstructors = mysql_fetch_assoc($rsInstructors));

echo ' All Emails Sent!</br>';

echo 'Back to Admin Home Page';


Kemahiran: Pemasukan Data, PHP, Memasang Skrip, Sistem Admin, Reka Bentuk Laman Web

Lihat lagi: you mail, uk mail, php send email script, sql server max, max sql server, type 1500, tries, sql script , sending mails, send mail as, php booking script, my mail, mail script, mail php, lesson php, iso, Instructors, html mail, e-mails, e-mail, e-mail database, e mail], amend, iso 8859 charset, send page email subject

Tentang Majikan:
( 0 ulasan ) Rotherham, United Kingdom

ID Projek: #330618