webmail / $toaddress issue
Posted: Mon Oct 12, 2009 3:38 am
I want a registration confirmation email to go out to the user and myself. Couldn't find much on the web on how to send to multiple email addresses via webemail. Did find something that utized bcc: via a $headers variable. Though, for some reason it didn't work. What am I doing wrong?
I also tried this $toaddress = $_POST['email'] && ';edawson003@myurl.com';
Code: Select all
$toaddress = $_POST['email'];
$subject = 'Welcome';
$mailcontent = 'Welcome '.$fname."\n\n"
.'Your username is: '.$_POST['username']. "\n"
.'message message message.'."\n";
$headers = 'From: newaccounts@myurl.com';
$headers .= "Bcc: edawson003@myurl.com\n";
mail($toaddress, $subject, $mailcontent, $headers);