karmakiller Posted April 4, 2007 Share Posted April 4, 2007 Hi, I hope you can help... I am trying to add a cc: (carbon copy to my email form... I am new to php and have tried alsorts but i cant get it to work... can some one please help. the code is below //Sending Email to form owner $pfw_header = "From: $email\n" . "Reply-To: $email\n"; $pfw_subject = "web enquiry"; $pfw_email_to = "[email protected],[email protected]"; $pfw_message = "Please Log As W/E\n\n" . "Title: $title\n" . "Firstname: $firstname\n" . "Surname: $surname\n" . "Address1: $address1\n" . "Address2: $address2\n" . "City: $city\n" . "Postcode: $postcode\n" . "Contact No: $contactno\n" . "Email: $email\n" . "Dishwasher: $dishwasher\n" . "Fridge Freezer: $fridgef\n" . "Washing Machine: $washer\n"; @mail($pfw_email_to ,$pfw_subject ,$pfw_message ,$pfw_header ) ; //then we put the details into the database //Below checkbox decs Link to comment https://forums.phpfreaks.com/topic/45520-add-cc-to-email-form/ Share on other sites More sharing options...
jitesh Posted April 4, 2007 Share Posted April 4, 2007 headers .= 'To: Mary <[email protected]>, Kelly <[email protected]>' . "\r\n"; $headers .= 'From: Birthday Reminder <[email protected]>' . "\r\n"; $headers .= 'Cc: [email protected]' . "\r\n"; $headers .= 'Bcc: [email protected]' . "\r\n"; // Mail it mail($to, $subject, $message, $headers); Link to comment https://forums.phpfreaks.com/topic/45520-add-cc-to-email-form/#findComment-221015 Share on other sites More sharing options...
karmakiller Posted April 4, 2007 Author Share Posted April 4, 2007 I have tried the following and I dont recieve mail at all now? any suggestions please $headers .= "To: [email protected]" . "\r\n"; $headers .= "From: $email\n" . "\r\n"; $headers .= "Cc: meagain@emailaddress" . "\r\n"; $subject = "test"; $message = "test\n\n" Link to comment https://forums.phpfreaks.com/topic/45520-add-cc-to-email-form/#findComment-221023 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.