Re: Newsletter on the way..stuck in the moment!
| From: | (Miles Thompson) | Date: | Fri, 06 Apr 2001 22:49:53 +0000 |
| Subject: | Re: Newsletter on the way..stuck in the moment! | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-47516@lists.php.net to get a copy of this message | ||
BCC - blind carbon copy
Miles
At 11:23 AM 4/6/01 -0700, Dhaval Desai wrote:
Hi! Well, I want to send an email to about 300 people. The problem is that if I use this method people can see all the email address of the people whoever it is sent to. <?php $connect = mysql_connect(); $query = "select email from news"; $execute = mysql_db_query("uaegraduate", $query); while($r = mysql_fetch_array($execute)) { $email = $r['email']; $add .= $email . ","; } $headers = "From: Webmaster@uaegraduate.com<Webmaster@uaegraduate.com>\n"; $headers .= "Content-Type: text/html; charset=iso-8859-1\n"; $subject = "hey"; $to = "$add"; $mailmessage = "hey this is the message"; $mailsomeone = mail($to, $subject, $mailmessage, $headers); if($mailsomeone) { echo "Success"; } ?> If I use the above method, all the email address will apear in the to: like this:- To:dhaval_adams@yahoo.com,roy@joy.com,xyz@xyz.com and goes on for 300 entries. Is there any way I can stop this from happening yet the mails reaching their destination. Thank You Cheers!~ Dhaval Desai __________________________________________________ Do You Yahoo!? Get email at your own domain with Yahoo! Mail. http://personal.mail.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net For additional commands, e-mail: php-general-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net