Here is a sample of my mail function:
//First email I send
$subject = "Your Membership at Lithuanian Global Genealogical Society!";
$message = "
Dear $first_name $last_name,
// Blah, blah, Blah
Username: $username
Password: $random_password
Thanks!
The Webmaster
This is an automated response, please do not reply!";
//Second email sent
$subject2 = "Membership Submission: $first_name $last_name";
$message2 = "
Dear Membership Coordinator,
$first_name $last_name has submitted the following information:
//Blah, Blah, Blah
First name: $first_name
Last Name: $last_name
Email: $mem_email_addr
Alternate Email: $mem_alt_email
Address: $mem_addr
City: $mem_city
State: $mem_state
Zip: $mem_zip
Country: $mem_country
This email is automatically generated!";
//My mail functions
mail($mem_email_addr, $subject, $message, "From: LGGS Webmaster<webmaster@lithuaniangenealogy.org>\nX-Mailer: PHP/" . phpversion());
mail($coordinator, $subject2, $message2, "From: LGGS Webmaster<webmaster@lithuaniangenealogy.org>\nX-Mailer: PHP/" . phpversion());
echo 'Your membership information has been mailed to your email address! Please check it and follow the directions!';
}
You can also modify the From section as needed, but I put that info into my set subject lines.
I have had no problems with the above.