Re: [PHP] CCO

2002-11-22 Thread Ernest E Vogelsinger
At 17:36 22.11.2002, Cesar Aracena said:
[snip]
>Now, I usually use a very comfortable way to configure e-mails by
>setting all the $vaiables first and then adding a mail() function at the
>bottom, but I never used a CCO target variable and never less a loop to
>fetch all the addresses... any thoughts?
>
>By the way, I'm very used to work with FOR loops, so I'll try to keep
>using it. Thanks in advance,
[snip] 

First of all be warned that most MTA's are set to allow only a specific
number of recipients for a single message as an anti-spam feature, so you
should limit the number of recipients accordingly to your MTA setup. If
you're not the admin you should ask how your MTA is configured.

http://www.php.net/manual/en/function.mail.php

Using mail() you can add additional headers as a fourth parameter. I
personally have never heard of the term "COO" but rather "Bcc", which means
"Blind CC". The above link has an example for Bcc mail that I will quote here.

[quote] 
/* To send HTML mail, you can set the Content-type header. */
$headers = "MIME-Version: 1.0\r\n"; 
$headers .= "Content-type: text/html; charset=iso-8859-1\r\n";

/* additional headers */
$headers .= "From: Birthday Reminder <[EMAIL PROTECTED]>\r\n";
$headers .= "Cc: [EMAIL PROTECTED]\r\n";
$headers .= "Bcc: [EMAIL PROTECTED]\r\n";

/* and now mail it */
mail($to, $subject, $message, $headers);
[/quote] 

In your case, just add up as much as "Bcc" headers as necessary or possble.
Add some fake address as "To", e.g. "Undisclosed-Recipients:;" (add the
colon follwed by a semicolon=, this _should_ work (haven't tested it, but
it _should at least ;->).


-- 
   >O Ernest E. Vogelsinger
   (\)ICQ #13394035
^ http://www.vogelsinger.at/



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP] CCO

2002-11-22 Thread Cesar Aracena
Hi all,

Before anything else, thanks for the answers to the last request of
mine. Now, I'm trying to make a mailing script which is a very common
task to do, but from this one, my client needs to send one e-mail to all
the recipients stored in a DB every once in a while. I know that is best
to send just one e-mail and add all the recipients to the hidden CC
(CCO) instead of adding all of them to the "TO" header.

Now, I usually use a very comfortable way to configure e-mails by
setting all the $vaiables first and then adding a mail() function at the
bottom, but I never used a CCO target variable and never less a loop to
fetch all the addresses... any thoughts?

By the way, I'm very used to work with FOR loops, so I'll try to keep
using it. Thanks in advance,

Cesar L. Aracena
[EMAIL PROTECTED]
[EMAIL PROTECTED]
(0299) 156-356688
Neuquén (8300) Capital
Argentina




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php