The mail() function included with stock PHP does not support SMTP authentication, for example. If mail() does not work for you then for this or another reason, try the PHPMailer package, which is much more comprehensive while maintaining, to a large extent, the simplicity and ease of mail() for sending mail from PHP. Mark the following points then proceed to code. You may also like Download simple HTML email templates and How to Send Emails using HTML and PHP.
$subject = "Test"; $to = "email@example.com"; $msg = "Type Your Message"; $headers='From: firstname.lastname@example.org \r\n'; $headers.='Reply-To: email@example.com\r\n'; $headers.='X-Mailer: PHP/' . phpversion().'\r\n'; $headers.= 'MIME-Version: 1.0' . "\r\n"; $headers.= 'Content-type: text/html; charset=iso-8859-1 \r\n'; $headers.= "BCC: firstname.lastname@example.org"; $headers.= "CC: email@example.com"; mail($to, $subject, $msg, $headers);