Skip to content

daviconcha/simple-system-html-php-css-mysql

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple System HTML PHP CSS MySQL

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.

Visual Examples

Below are visual examples of the Simple System:

Login Page

Login Page

Dashboard Page

Dashboard Page

Features

  • 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.

Project Structure

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.

Database Setup

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;

Database Configuration

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';

Getting Started

To start using the Simple System project:

  1. Clone the repository:
  2. git clone https://github.com/your-username/simple-system-html-php-css-mysql.git
  3. Set Up Database:
    • Create a MySQL database.
  4. Configure Database Connection:
    • Edit the config.php file in includes/php/ to enter your MySQL database credentials.
  5. 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.
  6. 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.

Contributing

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.

About

Simple System with HTML PHP CSS MySQL.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published