For the love of all that is good, PLEASE learn how to use databases securely before attempting real applications. Trust me, if you don't do this now, you'll be posting back in a few weeks wondering how your server got hacked.
Most important rules when accepting input from users:
1) ALWAYS ALWAYS ALWAYS validate your input!! Use regular expressions to scrub the input. Watch out for cross-site scripting. Cast variables as the appropriate data types. NEVER accept user input without cleaning it first
2) ALWAYS use [man]stripslashes[/man] and [man]addslashes[/man]! Never input data into your database without cleaning out potentially dangerous characters. This is how SQL-Injection attacks happen. Also checkout [man]mysql_escape_string[/man].
Believe me, you will save your self tons of aggrevation in the long run if you learn how to use databases correctly now rather than later.