I'm trying to create a simple form. When filled out on my site it is emailing to me but all the fields are not being sent. Here is the php code:
<?
$subject="from ".$_GET['name'];
$headers= "From: support@mysite.com";
mail("support@mysite.com", $subject, "
Contact Form
". "Email: " .$_GET['email'] .$_GET['message'].";
" . $headers);
echo ("Thank you for taking the time to fill out the form. Your message has been received. All issues will be responded to in the order which they were received.");
?>
<script>
resizeTo(300, 300)
//window.close()
</script
and here is the code on my site:
<h4>Contact form</h4>
<form id="form" method="get" target=”_blank” action="contact.php">
<div>
<label>Enter your name</label>
<input type="name" />
</div>
<div>
<label>Enter your e-mail</label>
<input type="email" />
</div>
<div>
<label>Enter your message</label>
<textarea name="message" cols="1" rows="1"></textarea>
</div>
<div class="buttons"><a href="#" class="link5" onclick="document.getElementById('form').submit()"><em><b>submit</b></em></a><a href="#" class="link5" onclick="document.getElementById('form').reset()"><em><b>reset</b></em></a></div>
The email is received but the only filled out information being sent is the message. However it is being sent like this:
subject: from
Contact Form
Email: This is the test message
From: support@mysite.com
I cant seem to figure out why the email isn't being sent properly. Any help is much appreciated. Thanks.