Skip to content
kirangautam45Public

About

Free 45-day core PHP & MySQL course for beginners: 20+ hands-on lessons from Hello World to sessions, password hashing, PDO and CRUD

Topics

Resources

Stars

3 stars

Watchers

0 watching

Forks

Latest commit

 

History

39 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PHP Learning Journey — 45 Days of Core PHP & MySQL

A free, beginner-friendly PHP course: 20+ hands-on lessons from "Hello World" to secure login systems and MySQL CRUD — no frameworks, just core PHP.

GitHub stars License: MIT PRs Welcome PHP MySQL

⭐ If these lessons help you learn or teach PHP, please star the repo — it helps other beginners find it.

Jump to: Lessons · Quick start · Guides · Full 45-day plan · Contributing

Who this is for

  • Beginners who know basic HTML and want to learn backend development
  • Teachers looking for a ready-made, day-by-day PHP curriculum
  • Developers who want to understand core PHP before jumping into Laravel

Every lesson folder has its own README.md explaining the concept, plus runnable example files.

Quick start

git clone https://github.com/kirangautam45/core-php.git
cd core-php/01-hello-world
php -S localhost:8000

Open http://localhost:8000 in your browser. For the database lessons (Day 16+), follow MYSQL_SETUP.md first.

Guides

Guide What it covers
php-learning-plan.md The full 45-day plan with daily topics
MYSQL_SETUP.md Installing and configuring MySQL
DATABASE_SETUP.md Creating the databases used in the lessons
SQL_BEGINNERS_GUIDE.md SQL basics for beginners: databases, tables and CRUD queries
GIT-GUIDE.md Everyday Git commands: setup, commits, branches
code-review-template.md Code review assessment for grading student projects

Progress Tracker

Completed Days

  • ✅ 01 - Hello World
  • ✅ 02 - Variables & Data Types
  • ✅ 03 - Operators & Conditionals
  • ✅ 04 - Loops
  • ✅ 05 - Arrays
  • ✅ 06 - Functions
  • ✅ 07 - Built-in Functions
  • ✅ 08 - Forms & GET/POST
  • ✅ 09 - Form Validation
  • ✅ 10 - Form Project
  • ✅ 11 - File Handling
  • ✅ 12 - File Upload
  • ✅ 13 - Sessions & Cookies
  • ✅ 14 - Password Hashing
  • ⬜ 15 - Login System (Student Task)
  • ✅ 16 - Database Basics
  • ✅ 17 - SQL CRUD
  • ✅ 18 - PHP-MySQL Connection
  • ✅ 19 - Insert Data
  • ✅ 20 - Fetch Data

Learning Plan Structure

Phase Days Topics
Phase 1 1-10 PHP Fundamentals
Phase 2 11-15 Files & Sessions
Phase 3 16-25 MySQL + PHP
Phase 4 26-40 CRUD Project (Notes App)
Phase 5 41-45 Best Practices & Next Steps

Phase Breakdown

Phase 1: PHP Fundamentals (Day 1-10)

  • PHP syntax, variables, data types
  • Operators and control structures
  • Loops and arrays
  • Functions (user-defined & built-in)
  • Forms, $_GET, $_POST
  • Form validation & sanitization

Phase 2: Working with Files & Sessions (Day 11-15)

  • File handling (fopen, fwrite, fread)
  • File uploads with validation
  • Sessions & cookies
  • Password hashing (password_hash, password_verify)

Phase 3: MySQL + PHP (Day 16-25)

  • Database fundamentals
  • SQL basics (CRUD operations)
  • PHP-MySQL connection (mysqli/PDO)
  • Prepared statements (SQL injection prevention)
  • Pagination & search

Phase 4: CRUD Project - Simple Notes App (Day 26-40)

A beginner-friendly notes application demonstrating:

  • User authentication (Register, Login, Logout)
  • Full CRUD functionality
  • Pin & archive notes
  • Search & filter by category
  • Color-coded notes
  • Responsive design
  • Security best practices

Tech Stack

  • Backend: PHP
  • Database: MySQL, SQLite
  • Database Library: PDO
  • Local Server: XAMPP / MAMP
  • Frontend: HTML, CSS

Getting Started

  1. Install XAMPP or MAMP
  2. Clone this repository to your htdocs folder
  3. Start Apache and MySQL services
  4. Navigate to any lesson folder and run: php -S localhost:8000

Project Structure

corephp/
├── 01-hello-world/
├── 02-variables-datatypes/
├── 03-operators-conditionals/
├── 04-loops/
├── 05-arrays/
├── 06-functions/
├── 07-builtin-functions/
├── 08-forms/
├── 09-form-validation/
├── 10-form-project/
├── 11-file-handling/
├── 12-file-upload/
├── 13-sessions-cookies/
├── 14-password-hashing/
├── 15-login-system/        # Student Task
├── 16-database-basics/
├── 17-sql-crud/
├── 18-php-mysql/
├── 19-insert-data/
├── 20-fetch-data/
├── DATABASE_SETUP.md
├── MYSQL_SETUP.md
├── SQL_BEGINNERS_GUIDE.md
├── php-learning-plan.md
└── README.md

Goals

By the end of this 45-day journey:

  • Build PHP web apps confidently
  • Create secure CRUD applications
  • Understand backend fundamentals
  • Be prepared for Junior PHP / Backend Developer roles

Resources

Contributing

Found a bug in an example, a typo, or have a better exercise idea? Contributions are welcome:

  1. Fork the repo and create a branch: git checkout -b fix/day-09-validation
  2. Make your change and commit it with a clear message
  3. Open a pull request describing what you changed and why

License

Released under the MIT License — free to use, adapt and teach from. Attribution is appreciated.


Made with ❤️ by Kiran Gautam · kirangtm.com.np
⭐ Star the repo if you found it useful!

About

Free 45-day core PHP & MySQL course for beginners: 20+ hands-on lessons from Hello World to sessions, password hashing, PDO and CRUD

Topics

Resources

Stars

3 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages