<?php
ob_start();
if(isset($_POST['name'])&&isset($_POST['email'])&&isset($_POST['message'])){
$name = $_POST['name'];
$email = $_POST['email'];
$message = $_POST['message'];
$to = "info@saarnav.com";
$subject = "Contact Email From Saarnav ".$name;
$txt = "A Mail Come from ". $email. "\n\n". "\n The Name of Sender is ".$name."\n\n"."The Message of send is \n\n".$message ;
$headers = "From:".$email." " . "\r\n" ;
mail($to,$subject,$txt,$headers);
}
header('location:index.html');
exit();
?>
ob_start();
if(isset($_POST['name'])&&isset($_POST['email'])&&isset($_POST['message'])){
$name = $_POST['name'];
$email = $_POST['email'];
$message = $_POST['message'];
$to = "info@saarnav.com";
$subject = "Contact Email From Saarnav ".$name;
$txt = "A Mail Come from ". $email. "\n\n". "\n The Name of Sender is ".$name."\n\n"."The Message of send is \n\n".$message ;
$headers = "From:".$email." " . "\r\n" ;
mail($to,$subject,$txt,$headers);
}
header('location:index.html');
exit();
?>
No comments:
Post a Comment