This repository serves as an experimental project to demonstrate PHP and MySQL database usage.
This repository showcases the usage of PHP and MySQL for creating a basic authentication system and interacting with a database.
To run this project on your local system, follow the steps below:
-
Download XAMPP from the official website: https://www.apachefriends.org.
-
Install XAMPP on your local system.
-
Start the XAMPP server and ensure that Apache and MySQL are running.
-
Open your preferred web browser and navigate to
http://localhost/
. -
Create a new database called
auth_db
. -
Inside the
auth_db
database, create two tables namedauth
andcustomer
. -
Run the following SQL command to create the
auth
table:CREATE TABLE auth ( id INT AUTO_INCREMENT PRIMARY KEY, username VARCHAR(50), password VARCHAR(50) );
-
Insert sample data into the
auth
table by running the following SQL command:INSERT INTO auth (username, password) VALUES ('admin', 'admin'), ('customer1', 'customer1'), ('customer2', 'customer2');
-
Inside the
customer
table, run the following SQL command:CREATE TABLE customer ( id INT AUTO_INCREMENT PRIMARY KEY, order_date DATE, company VARCHAR(50), owner VARCHAR(50), item VARCHAR(50), quantity INT, weight FLOAT, shipment_request VARCHAR(50), tracking_id VARCHAR(50), shipment_size VARCHAR(50), box_count INT, specification VARCHAR(50), checklist_quantity VARCHAR(50) );
The project demonstrates various PHP functionalities and how to interact with a MySQL database. Feel free to explore the code and customize it as per your requirements.