Hi Everyone,
i need urgent help from you.iam trying to send mail using php mail() functions.iam using XAMPP server.if i run above code iam getting "succesfuuly sent" message as a output but iam not getting any mail in my inbox address.please help methis is my code.
<?php
if(isset($_POST['submit']))
{
$name=$_POST['name'];
$age=$_POST['age'];
$address=$_POST['address'];
$comment=$_POST['comment'];
$to="shashigowda@example.com";
$subject="Details";
$message="hi $name.you are $age years old.and your current address is $address.";
$retval=mail($to,$subject,$message);
if($retval==true)
{
echo "succesfully sent";
}
else
{
echo "try again";
}
}
?>
<!DOCTYPE>
<html>
<head>
</head>
<body>
<form action="mail.php" method="POST">
Name:<input type="text" name="name" required>
Age:<input type="number" name="age" required>
Adress:<input type="text" name="address" required>
Comment:<textarea row="4" col="10" name="comment"></textarea><br />
<input type="submit" name="submit" value="submit">
</form>
</body>
</html>