bool mail(string to, string subject, string message, string
additional_headers). mail("admin@yourdoamin.com, test@test.com, next@yourdomain.com",
"Test subject",
"Test\n message body\n\n End line"); $email="admin@yourdomain.com, admin@otherdomain.com";
$subject="Test subject";
$letter="Test\n message body\n\n End line";
mail($email, $subject, $letter);
So owner of the e-mail address admin@yourdomain.com receives
"Test msubject" letter. You can control Reply-To, From message fields and other special
fields passing the info into additional parameters string in the last mail()
function argument. mail("admin@yourdomain.com",
"Test letter 2",
"Test\n body 2\n\n End line",
"From: webmaster@$SERVER_NAME\nReply-To: webmaster@$SERVER_NAME\nX-Mailer:
PHP/" . phpversion());
Additional mail message fields separated by new line symbol (\n).
mail($email, "Subscription",
"$letter",
"From: test@abcdefg.com\nReply-To: test@abcdefg.com\nX-Mailer: PHP/" .
phpversion());If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.