I'm new to php, i just start to use mail function. I have a problem like below:
Suppose, i have more recipients than one that will get my email.
<?php
$to = $_POST['to']; //xxxxx@yahoo.com,yyyyy@yahoo.com,zzzzz@yahoo.com
$from = $_POST['from']; //aaaaa@yahoo.com
$from = "myinfo <$from>";
$subject = $_POST['subject']; //New campiagn
$content = $_POST['content'];
$headers = "From:" . $from;
mail($to,$subject,$content,$headers);
?>
The code above work correctly. But when user get this email, they will see:
To Me, yyyyy@yahoo.com, zzzzz@yahoo.com
I don't want all users that get this email show when user view this email. Below is what i want:
To myuser@info.com
Does it is possible to do like this? I'm appreciate to all of your answer :)
Thank in advance
If you use a list in the To:
field of a regular mail client the list will appear to every recipient. This is normal behaviour. If you want to hide the list then your best option is to send each recipient their own individual copy.