View Full Version : php contact form

12-19-2008, 01:34 PM
I have a contact form but I'm not very good with PHP and the contact form is rather long so when i try to use the free online ones when i go to add information it just doesn't submit and i also have a list box which i don't know how to cater for.

I also would like it to submit to a database because all through testing these contact forms the emails don't seem very reliable and take up to a day to send.

So does anyone have any contact form tutorials that submit to a database that will show me how to submit a list box as well.

Thanks for the help.

12-19-2008, 02:08 PM
Here is a simple contact form that I am typing out myself.

echo '<form action="send.php" method="post">
echo 'Please fill out the information below to contact us.<br />';
echo 'Name: <input type="text" name="name" value=""><br />';
echo '<select name="gender">';
echo '<option value="male">Male</option> <option value="female">Female</option></select><br />';
echo '<input type="submit" name="submit" value="Contact Us">';

Then in the isset just pull the POST information and put it in a query. Done

12-19-2008, 02:16 PM
Sorry how do i pull the isset?

Also how do i put it in a query, i'm a designer and not a coder so i don't know anything about it.

I need it to connect to phpmyadmin to store it in a database also.


12-19-2008, 02:27 PM
Check some samples at http://www.tizag.com/phpT/examples/formex.php and http://www.w3schools.com/PHP/php_mysql_insert.asp