Jump to content

Skelly123

New Members
  • Posts

    7
  • Joined

  • Last visited

    Never

Everything posted by Skelly123

  1. Alright, well, I removed the debugging code from the original php, and now the form is posting to the database terrifically without it. Case closed! Thank you, everyone, for helping me!
  2. Woah! Ok, I entered in the debugging code into the php, filled out the form, pressed the submit button, and here is what appeared on the next screen: Then I checked the daabase, and voila! It posted! Now I'm going to remove that debugging code from the php and try again. Give me a few minutes. Thank you!
  3. Hi PFMaBiSmAd, Thanks for trying out the code independently. There must apparently be something going wrong with the MySQL I am using via Starfield Technologies (the company Godaddy uses for phpmyadmin). It's the only thing I can think of if the code works for you and not me. I did update the form. You can view it at the following URL. http://mtgcodex.com/testdatabase/form.htm As I said before, the database is registering the receipt of information, but then (as shown in my screen caps), no data appears other than the primary key. Any other ideas?
  4. Ok, I dumped the code into MS Word to be able to see the smart quotes better. I changed all the smart quotes in Notepad so they look right. FTP'd the file in. No change - info still not appearing in database. Here is the form code now. Boy, I was really hoping that would be it.
  5. Hi Wild Teen, Thank you for responding. Here is the result of "describer table1." I hope this is what you were asking for. By using the php code in my previous post, was I sanitizing properly? Or is there something else I need to do to the php code still? Now that I know sanitizing is simply good practice, I'll be sure to add in the relevant code in the future.
  6. Hi jonsjava, Thanks so much for giving me the time of day! I did precisely as you instructed. Here is what my php looks like now: So, here is the effect it had. The echo "1 record added" still appeared after submission with no errors. My data still did not appear in the database, but what happened was that the new submission (#30) was placed at the beginning of the table (the top) as opposed to the end (the bottom). Here is a screen cap to illustrate: Previously the new data was being placed at the bottom of the table in chronological order. So unfortunately, this is still a mystery that remains unsolved.
  7. 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]
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.