Welcome to the Simple System project repository! This project showcases a basic implementation using HTML, PHP, CSS, and MySQL. It currently features user authentication with session management and database verification.
Below are visual examples of the Simple System:
Login Page
Dashboard Page
- User Authentication: Enables users to securely log in using their email and password credentials.
- Session Management: Manages user sessions to maintain authentication across multiple pages.
- Database Integration: Utilizes MySQL database to store and verify user credentials.
The project structure includes the following components:
index.php:
Entry point of the application, contains the login interface and initial session handling.assets/css/style.css:
CSS file providing styling for the project's interface.includes/php/:
action_form.php:
Handles form submissions and database operations for user authentication.check_session.php:
Validates user sessions to ensure authenticated access to protected pages.config.php:
Configuration file for database connection details.logout.php:
Logs users out by destroying sessions and redirecting to the login page.
parts/:
menu.php:
Contains the menu structure for navigation within the application.parts/dashboard/:
index.php:
Placeholder for future dashboard functionality.
Set up your MySQL database with the following SQL schema:
CREATE TABLE `auth` (
`id` int(11) NOT NULL,
`email` varchar(60) NOT NULL,
`password` varchar(60) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
INSERT INTO `auth` (`id`, `email`, `password`) VALUES
(1, 'admin@admin.com', 'admin');
ALTER TABLE `auth`
ADD PRIMARY KEY (`id`);
ALTER TABLE `auth`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;
Configure your database connection by editing the config.php
file located in includes/php/
.
DB_SERVER = 'localhost';
DB_USERNAME = 'root';
DB_PASSWORD = '';
DB_NAME = 'project_php01';
To start using the Simple System project:
- Clone the repository:
- Set Up Database:
- Create a MySQL database.
- Configure Database Connection:
- Edit the
config.php
file inincludes/php/
to enter your MySQL database credentials. - Run the Application:
- Ensure you have a web server (e.g., Apache, Nginx) with PHP installed and running.
- Navigate to the project directory on your local server using a web browser.
- Explore and Customize:
- Explore the project structure to understand its organization and functionality.
- Customize the project as needed or use it as a learning resource.
git clone https://github.com/your-username/simple-system-html-php-css-mysql.git
Contributions are welcome! If you encounter issues or have suggestions for improvements, feel free to open an issue or submit a pull request. Your contributions help enhance this project for everyone.