I have a script set to take some form variables and email them to xyz@xmind.net
I want to add a copy to abc@xmind.net but am not sure how to do that. I tried putting a second email into the $toaddress separating with a ; like this:
$toaddress = "xyz@xmind.net; abc@xmind.net";
That didn't work. Here is the code:
<?
$toaddress = "xyz@xmind.net";
$subject = "Member Renewal";
$headers .= "From: [email]renew@xyz.com[/email]\n";
$headers .= "Reply-To: [email]info@xyz.com[/email]\n";
$headers .= "MIME-Version: 1.0\n";
$headers .= "Content-Type: text/html; charset=iso-8859-1\n";
$headers .= "X-Priority: 1\n";
$headers .= "X-Mailer: PHP / ".phpversion()."\n";
$headers .= "Return-Path: [email]info@xyz.com[/email]\n";
$mailcontent = "The following member renewal has been submitted: <br><br>"
."Member Name: ".$MbrName."<br>"
."Clinic Name: ".$ClinicName."<br>"
."Address: ".$Address."<br>"
."Address2: ".$Address2."<br>"
."City, State Zip: ".$City.", ".$State." ".$Zip."<br>"
."Phone: ".$Phone."<br>"
."Fax: ".$Fax."<br>"
."Email: ".$Email."<br>"
."Website: ".$Website."<br>"
."Addlink: ".$Linktosite."<br>"
."Ownership: ".$Ownership."<br>"
."Ownership Other: ".$OwnershipOther."<br>"
."Joined OMGMA: ".$OMGMAYYYY."<br>"
."Joined MGMA: ".$MGMAYYYY."<br>"
."Practice Specialty: ".$MedSpecialty."<br>"
."# Physicians: ".$Physicians."<br>"
."# PAs: ".$PAs."<br>"
."# NPs: ".$NPs."<br>"
."Spouse: ".$Spouse."<br>";
mail("$toaddress", "$subject", $mailcontent, $headers);
?>