I am working on a site locally and I am trying to add a contact form to it.
I've added a simple form on: http:localhost:8888/testsite/contact.php
, when the user clicks on the submit button I want them to be redirected to another page with a message on it. The page I want the user to go to after submitting the form it: contact_message.php
.
I've created both files and they both display OK on there URLs- http:localhost:8888/testsite/contact.php
and http:localhost:8888/testsite/contact-message.php
however the form isn't working because when you click submit the url changes to: http:localhost:8888/testsite/contact.php/contact-message.php
, which would be fine if it showed the contact-message.php
content, but it doesn't.
The code fore the form is:
<form method="post" action="contact-message.php">
<table>
<tr>
<th>
<label for="name">Name</label>
</th>
<td>
<input type="text" name="name" id="name">
</td>
</tr>
<tr>
<th>
<label for="email">Email</label>
</th>
<td>
<input type="text" name="email" id="email">
</td>
</tr>
<tr>
<th>
<label for="message">Message</label>
</th>
<td>
<textarea type="text" name="message" id="message"></textarea>
</td>
</tr>
</table>
<input type="submit" value="Send">
</form>
Does anybody have any ideas?