Hi I'm trying to make a feed back form for php and it worked but I was just wondering, can i make a set of code also deliver this email to the visitor who sent this mail? Also tagged along with a small message like "Thank you, for your feedback. This is the message you wrote ".....". and here is my code:
<?php
$myemail = "****@myemail.com";
$ccx = "";
if(!$visitormail == "" && (!strstr($visitormail,"@") || !strstr($visitormail,".")))
{
echo "<h2>Use Back - Enter valid e-mail</h2>\n";
$badinput = "<h2>Feedback was NOT submitted</h2>\n";
}
if(empty($visitor) || empty($visitormail) || empty($notes )) {
echo "<h2>Use Back - fill in all fields</h2>\n";
}
echo $badinput;
$todayis = date("l, F j, Y, g:i a") ;
$attn = $attn . "(" . $ccopy . ")" ;
$subject = $attn;
$notes = stripcslashes($notes);
$message = " $todayis \n
From: $visitor ($visitormail)\n
Website URL: $weburl \n
Message: $notes \n
Additional Info : IP = $ip \n
Browser Info: $httpagent \n
Referral : $httpref \n
";
$from = "From: $visitormail\r\n";
if (($ccopy == "ccyes") && ($visitormail != ""))
mail($visitormail, $subject, $message, $from);
if ($myemail != "")
mail($myemail, $subject, $message, $from);
if ($ccx != "")
mail($ccx, $subject, $message, $from);
?>
Ohh one more thing is it possible to change the timestamp to asia? +8gmt? I my knowledge is pretty little in php. Thanks!