i have a problem of sending am emial to an organisation and also a mail will be sent as an acknowledgment to the person who send the mail. please if possible send me code as soon as possible.
hi !!!! thanx for viewing my problem. I want to send an email as Cc and Bcc in php. i have a code as below. please send me the code in which the email will be send as Cc and Bcc <?php } // If there were no errors, send an email to the organisation staff. else { $message = "This message has been generated by the organisation staff.'Contact Us' page. Contact details for the sender are given below.\r\n\r\n"; $message .= "Name: $name\r\n\r\n"; $message .= "Address:\r\n"; $message .= "$number $street\r\n"; $message .= "$suburb, $state\r\n"; $message .= "$postcode\r\n\r\n"; $message .= "Phone #: $phone\r\n"; $message .= "Email: $email\r\n\r\n"; $message .= "Comments:\r\n"; $message .= "$comments"; $headers = "Return-Path: <$email>\r\n"; // This line uses a friendly name 'No Reply' and causes errors $headers .= "From: No Reply <webmaster@hvc.org.au>\r\n"; // $headers .= "From: \r\n"; // this line doesn't use a 'friendly name' and seems to work $headers .= "From: <$email>\r\n"; //added by PY 18-10-07 so that emails come from the address supplied $headers .= "User-Agent: HVC contact form\r\n"; $subject = "HVC Contact form"; // The following line is where the prob occurs. info@hvc is an address for a public folder, and it can't seem to send to that, but can send to an Active Directory account // Update 18-10-07 re-enabled the following line. Now it works - go figure!! if ($trap == ''){ if (mail("info@hvc.org.au", "$subject", "$message", "$headers")){ echo '<h1>Thank You</h1>'; echo '<p>The information you entered has been forwarded to the staff at HVC.</p>'; echo '<p> </p>'; echo '<p> </p>'; } } } ?> please send me the code as soon as possible.