Custom PHP MVC Architecture

Intern Rift — Web4All Platform

PHP 8+Custom MVCEloquent ORMMySQLTwig

Overview & Objective

A comprehensive web platform connecting engineering students, partner companies, and academic coordinators. Built entirely with a custom PHP 8 MVC architecture without heavyweight frameworks (like Laravel/Symfony) to master fundamental software engineering design patterns, routing pipelines, Eloquent ORM database relationships, and strict PSR-12 coding standards.

Architectural Overview

Routing Pipeline (index.php)

Single entry-point front controller parsing request URIs, enforcing middleware, and dispatching to controller actions.

Domain Controllers (src/Controllers)

Dedicated business logic controllers: OfferController, CompaniesController, and ApplicationController.

Database & Eloquent ORM (src/Models)

Eloquent ORM relationships (BelongsTo, HasMany) mapping relational tables while preventing SQL injection vulnerabilities.

Twig Views (src/Views)

Clean template inheritance separating business logic from responsive HTML5/CSS3 presentation.

Key Engineering Highlights

Custom Front-Controller MVC Architecture

Engineered an independent router (index.php), decoupled domain controllers, and Twig template rendering to strictly enforce separation of concerns.

Role-Based Access Control (RBAC)

Implemented granular permission systems tailored to Students (offer discovery, wishlists, applications), Companies (offer authoring), and Academic Coordinators (tracking dashboards).

Robust Security & Data Integrity

Enforced SQL injection immunity via Eloquent ORM prepared statements, automated XSS input sanitization (InputValidator), and secure UUID-based file upload storage.

Relational Database Modeling

Structured multi-table schema with PHP migrations, foreign key constraints, and pivot tables managing application lifecycles.