Using sql and form on web page

i am a beginner and am interested to set up a form on a web page and
have the data sent to a data base in mysql. however, i havnt the
knowledge of how to set it up… can you simplify it for me beginning
with the form all the way to where the data arrives in the data base.

try this excellent PHP/MySQL tutorial


A very simple script

Contents of file start.html:

Contents of file finish.php:

<?php mysql_connect("", "user_name", "user_password"); $db = mysql_select_db("database"); $sql = "INSERT INTO table VALUES('" . $_POST['first_name'] . "')"; $result = mysql_query($sql); if($result){ echo "Thank you " . $_POST['first_name'] . ", your name has been added to the database"; } else{ echo "Your name have not been added!"; } ?>

Using a little common sense you should be able to understand that. But I recommend looking for more examples.
You can try too for lots of tutorials on different languages.