Posts

Showing posts from March, 2026

Module #10

Image
    website link -  tericiar.infinityfree.me/module4.php In this module, I learned how to connect PHP to a MySQL database and insert data from an HTML form into a database table. At first, it seemed a little tricky because you have to make sure your PHP script can actually “talk” to the database, but once I got the hang of it, it started making sense. We started by creating a table in MySQL using phpMyAdmin. I set up columns for first name, last name, and email so that when someone fills out the form, their information has a place to go. Then, I created a simple HTML form where users can type in their information. The form uses the POST method to send the data, which is important because it keeps the information secure and organized. The really interesting part was writing the PHP script to handle the form data. I used the $_POST superglobal to grab the data from the form and then used an SQL INSERT statement to put it into my MySQL table. I also learned that connecti...

Module #9 Assignment

Image
  Creating My First MySQL Table For this assignment, I created my first MySQL table using InfinityFree and phpMyAdmin. The process had three main steps: creating the database, designing the table, and inserting data. Step 1: Create a New Database I started by logging into InfinityFree and opening cPanel. I clicked “Create New MySQL Database”, gave it a name, and saved it. This step was pretty easy since the interface guided me through it. The only slightly confusing part was understanding that the database is just a container for the tables I’ll create. Step 2: Design the Table Next, I opened phpMyAdmin and selected my database. I created a new table called MyFirstTable with three columns: FirstName, LastName, and Age. I chose VARCHAR for the name columns and INT for age. This step was a bit tricky because I had to decide which data type to use for each column, but once I understood INT vs VARCHAR, it made sense. Step 3: Insert Data Finally, I clicked the Insert tab in phpM...

Module #8 Assignment

1. What is the difference between $_Get vs. $_POST?  In PHP, $_GET and $_POST are used to collect data from forms, but they work a little differently. $_GET sends the data through the URL, so anything someone types into the form shows up in the browser’s address bar. It’s usually used for small amounts of information or data that doesn’t need to be private. $_POST sends the data behind the scenes in the request instead of the URL, which makes it more secure, especially for sensitive info or larger data. So, the main difference is that $_GET shows the info in the URL, while $_POST keeps it hidden. website link -  Message Form