When the submit button is clicked, the browser goes to www.****.com/contact.php and the page is blank. The email is also not delivered. This is my first time dealing with php. What am I missing?
Here is the form:
<form class="comment-form" action="contact.php" method="POST">
<p class="comment-notes">Your email address will not be published. All fields are required.</p>
<p class="comment-form-email">
<label for="author">Name</label>
<span class="required">*</span>
<input id="author" type="text" class="input-text" name="name">
</p>
<p class="comment-form-author">
<label for="email">Email</label>
<span class="required">*</span>
<input id="email" type="text" class="input-text" name="email">
</p>
<p class="comment-form-url">
<label for="subject">Subject</label>
<span class="required">*</span>
<input id="subject" type="text" class="input-text" name="subject">
</p>
<p class="comment-form-comment">
<label for="message">Message</label>
<textarea name="message" id="message" cols="45" rows="10" class="input-text"></textarea>
</p>
<p class="form-submit">
<input class="btn btn-md btn-default" name="submit" type="submit" id="button" value="Send"><input type="reset" value="Clear">
</p>
</form>
<?php
$name = $_POST['name'];
$email = $_POST['email'];
$formcontent = "From: $name\n Message: $message";
$recipient = "me@example.com";
$subject = "$subject";
$mailheader = "From: $email \r\n";
error_reporting(E_ALL);
ini_set(display_errors, 1);
mail($recipient, $subject, $formcontent, $mailheader) or die ("Error!");
echo "Thank You! We will respond to your inquiry as soon as possible"; " -"<a href='contact.html' style='text-decoration:none;color:#ff0099;'> "Return Home"</a>;
?>