format('(Y-m-d H:i)'); // Could also be $subject = $_POST['subject']; $message = 'This is the email message body'. $_SERVER['REMOTE_ADDR']; // Could also be $message = $_POST['message']; $h = "\r\n"; $headers = 'From: pete '. $h. 'BCC: ph@westconn.com.au'. $h. 'Reply-To: castagna@enigma.com.au'. $h. 'X-Mailer: PHP/' . PHP_VERSION; //$headers = implode("\r\n", [ // 'From: pete ', // 'Reply-To: castagna@enigma.com.au', // 'X-Mailer: PHP/' . PHP_VERSION //]); $res = mail($to, $subject, $message, $headers); echo $res. $to. $subject. $message. $headers; ?>