Woo-Hoo! I’m King of All the Web Developers!

Previously:

After months of blood, sweat, googling, tears, and whining & ranting blog posts, I have succeeded in setting the World Wide Web on fire.

I finally found a few tutorials that weren’t completely worthless (but weren’t exactly something I’d link to and recommend … in fact, I could rant about one and its author in particular but I’m in too good of a mood), was able to make enough sense of them that I could combine them into something that worked and didn’t suck. By no means is this little project finished–there’s more experimentation, playing, and learning to do, but I made (a MySQL database, table, and) three files:

  • An HTML form
  • A PHP file in the same directory. It carries the data from HTMLformland to MySQLland in part by referring to …
  • A Super-Secret PHP file that lives in a non-public directory.

Here’s my humble form for entering information about Presidents of the USA:

A simple HTML form

My first attempt resulted in this:

Error Message

Easy fix. I’d just put the same value in for the database name and the table name. So …

Success message

But here’s what I don’t understand. The first attempt didn’t work and yet …

PHPmyAdmin showing two rows in a table

So what happened there?

Best news besides the whole thing working flawlessly is I can’t see any of the code in either of the PHP files.

Advertisements

About jotascript

Aiming to please. Seeking to impress.
This entry was posted in PHP, Web Development and tagged . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s