Hi there everyone,
I'm a first time poster, and I'm here because I'm, well, desperate. I'm just learning MySQL and PhP - I'm doing it online through tutorials, though I'd rather learn it in a classroom. What I am trying to do is send form data from a basic html form to a MySQL database. Super simple (so I thought), but what is happening is that when I fill out the form and hit "Submit" button, the echo text appears saying "1 record added," but then then when I go to check the database using phpmyadmin, the info I entered into the text boxes on the form does not appear there. I set up a id field with an automated integer as a primary key to see if I could track whether communication was really coming into the database from the form, and sure enough, each time I hit "submit" on the form, a new row is created in the database with the next chronological number - but all fields afterward are blank.
Here is my code I am using:
Form Code
And the php:
I am using MySQL version 5.0. I am accessing phpmyadmin through Godaddy (my host). I am receiving no errors. I created my database table using phpmyadmin, so I do not have a CREATE TABLE code for you, but here is a screencap of what my table looks like after I perform an SQL query:
Notice that the "id" column is filling each time I submit, so it seems to be functioning (note - I manually deleted numbers 1-26). Again, I want my submitted information to show in the database. Other than the data not appearing, everything else seems to be working properly. I have tried different variations of code on the internet to try to solve this problem, but they all return errors. I am open to trying any suggestions that anyone here might have. I run a few different websites all on the same hosting plan and I have created databases on each to try to test this out, and in every instance information is submitted but not recorded to the database. What am I doing wrong?
[attachment deleted by admin]