Don't know why i'm getting this error for my contact form i'm new to php
. Hope you can help me with this
Parse error: syntax error, unexpected 'if' (T_IF) on line 2
Code:
<? php
if (isset($_POST['submit'])) {
$name = $_POST['name'];
$mailFrom = $_POST['email'];
$Phone = $_POST['phone'];
$Message = $_POST['message'];
$Select = $_POST['project'];
$mailTo = "info@amaravathiestates.in";
$headers ="From: ".$mailFrom;$txt = "You have received an email from " .$name ".\n\n" .$Message ".\n\n" "Phone Number:" .$Phone ".\n\n" "Project Visit:" .$Select;
mail($mailTo,$txt,$headers);
header("Location: Contact-Us.html");
};