sending form data
Hi there,
I am trying to find out how to send form data from my website back to me (using a 'submit' button) either via email or to a database and where I put this coding in relation to the actual form coding.
Here is my form coding:
<link href="mainform.css" type="text/css" rel="stylesheet" />
<div id="form">
<h2 align="left">Feedback Form</h2>
<p><span style="FONT-SIZE: 14pt">Please fill out the form below to pass on your query. If you have any urgent questions, don't hesitate to </span><a href="index.php?p=1_46"><span style="FONT-SIZE: 14pt">contact us</span></a> <span style="FONT-SIZE: 14pt">.</span></p>
<form action="feedback.php" method="post">
<p class="legend"><strong><span style="FONT-SIZE: 14pt">Personal information</span></strong></p>
<fieldset id="personal">
<label>Name:</label>
<input style="BACKGROUND-COLOR: rgb(255,255,160)" size="30" name="name" /><br />
<label>Address:</label>
<input style="BACKGROUND-COLOR: rgb(255,255,160)" size="30" name="address" /><br />
<label>Town/City:</label>
<input style="BACKGROUND-COLOR: rgb(255,255,160)" size="30" name="city" /><br />
<label>State:</label>
<input style="BACKGROUND-COLOR: rgb(255,255,160)" maxlength="3" size="3" name="state" /><br />
<label>Postcode:</label>
<input style="BACKGROUND-COLOR: rgb(255,255,160)" maxlength="5" size="5" name="postcode" /><br />
<label>Phone:</label>
<input style="BACKGROUND-COLOR: rgb(255,255,160)" maxlength="10" size="10" name="phone" /><br />
<label>Email:</label>
<input style="BACKGROUND-COLOR: rgb(255,255,160)" size="40" name="email" /><br />
</fieldset>
<p class="legend"><strong><span style="FONT-SIZE: 14pt">Choices</span></strong></p>
<fieldset id="choices">
<p id="querytype">
<label>Type of Query:</label>
<select name="querytype">
<option value="Compliment">Compliment</option>
<option value="Suggestion">Suggestion</option>
<option value="Complaint">Complaint</option>
<option value="Question">Question</option>
</select></p>
<p id="size">
<label>Size:</label>
<input type="radio" value="'F" name="size" ?? />Freestyle Aerobics
<input type="radio" value="W" name="size" />Wedding Dance
<input type="radio" value="'D" name="size" ?? />Dance
<input type="radio" value="M" name="size" />Music Editing
<input type="radio" value="T" name="size" />Translation </p>
<p id="extras">
<label>Extras:</label>
<input type="checkbox" value="salsa" name="extras[]" />Salsa
<input type="checkbox" checked="checked" value="zouk" name="extras[]" />Zouk
<input type="checkbox" value="hiphop" name="extras[]" />Hip Hop
<input type="checkbox" value="instructorworkshops" name="extras[]" />Instructor Workshops <br />
</p></fieldset>
<p class="legend"><strong><span style="FONT-SIZE: 14pt">Suggestions</span></strong></p>
<fieldset id="suggestions">
<style type="text/css">
<!--
textarea.html-text-box {background-color:ffffff;background-repeat:no-repeat;background-attachment:fixed;border-width:1;border-style:solid;border-color:cccccc;font-family:Arial;font-size:8pt;color:0000FF;}
input.html-text-box {background-color:ffffff;font-family:Arial;font-size:8pt;color:000000;}
-->
</style>
<textarea class="html-text-box" name="comments" rows="10" cols="100">Enter your comments here...></textarea><br />
</fieldset>
<p id="buttons">
<input type="submit" value="Submit" />
<input type="reset" value="Start Over" /></p>
<fieldset></fieldset>
</form></div>
I have saved 'feedback.php' to my remote root folder.
ANyway, hopefully someone can help. If you can, please be as precise as possible, as I am not a wiz at this stuff.
Thanks heaps in advance!!
Terry
|