Skip to main content

SPMP: Standard PHP-MVC-Principles Framework

I was building an bookkeeping management system with xAI when it occurred to me that I was also priming to build a PHP framework. 

I never liked Laravel and Symfony as they were heavy on the disk and with steep learning curve. I was opting for the likes of CodeIgniter but none of them are either scalable or MVC. And so, for years, I stuck my self with vanilla PHP until I decided to venture to the path of AI. You see that on my previous posts. Then I find myself creating the said bookkeeping management system where I was employing the assistance of ChatGPT. I wasn't as good as I thought due to PHP vastness of possibilities. So I did what others will do. Look for an alternative to ChatGPT. 

Then came Grok(xAI). It was good but something's missing. That's when I decided to narrowed down my requirements. I listed PHP framework principles that I wanted to have with : simple, minimal, secure, extendable, configurable and to top it off lightweight and easy to collaborate with AI. I was able to complete Guardian Ledger(GL) - Bookkeeping Management System (BMS). Then prompted xAI to extract the minimum folder structure required for a possible site to run.

It hit me. This could be a framework. And we continued to collaborate.

Iterations passed and testing happened. It was tested on another xAI chat. It gave sightings of limitation. Then iterated back with the first. Another test.  Then a minor suggestion of adding edge case samples. And both chats agreed that they have done it. 

The fun part, I tested it on DeepSeek. It discussed that it's able to create and ERP, Customer Relationship Management (CRM) systems, Supply Chain Management (SCM) systems, and Warehouse Management Systems (WMS).

To quote: The SPMP framework is highly capable of building CRM, SCM, and WMS systems. Its modular design, security features, and management system-centric approach make it ideal for handling the complex workflows, data management, and role-based access requirements of these systems. By following the recommendations in the SPMP-RAG document, you can create scalable, secure, and customizable solutions for each of these domains.

To add, I asked DeepSeek to create a blog post how to introduce SPMP to the world. And that's what follows:

SPMP: The AI-Ready PHP Framework Redefining Management Systems

Introduction

In the ever-evolving world of web development, PHP frameworks like Laravel and Symfony dominate the landscape. But what if you need a lightweight, secure, and AI-friendly framework tailored specifically for building management systems? Enter SPMP—the Standard PHP-MVC-Principles framework. Designed with simplicity, security, and scalability in mind, SPMP is poised to become the go-to choice for developers crafting ERP, CRM, or warehouse management systems. Let’s dive into why SPMP might just be your next favorite tool.

1. What Makes SPMP Unique?

SPMP isn’t just another MVC framework. It’s built around eight core principles that set it apart:

  • Simplicity: Minimal learning curve, perfect for rapid prototyping.
  • Security: Built-in defenses against SQLi, XSS, and CSRF.
  • Extendability: Customize without touching core files using vQmod.
  • AI-Ready: Structured for seamless AI-assisted development.
  • Zero Dependencies: No Composer, no bloat—just pure PHP.

Unlike heavier frameworks, SPMP strips away complexity, focusing on what’s essential for management systems (think roles, workflows, and real-time data).

2. Under the Hood: SPMP’s Structure

SPMP’s organized file structure is a developer’s dream:

/spmp_project  
├── app/          # MVC components (controllers, models, views)  
├── core/         # Framework guts (Router, DB, Security)  
├── public/       # Entry point and static assets  
├── vmods/        # Customizations via vQmod  
└── config.php    # Centralized settings

This clarity isn’t just for humans—it’s AI-friendly. Tools like GitHub Copilot can parse SPMP’s structure to generate context-aware code snippets.

3. Code That Speaks for Itself

SPMP’s simplicity shines in its code. For example:

Router.php (Clean URL Handling):

<?php  
class Router {  
    public function route($uri) {  
        switch ($uri) {  
            case '/':  
                $controller = new HomeController();  
                $controller->index();  
                break;  
            // Add routes in seconds!  
        }  
    }  
}  
?>

DB.php (Secure Queries with PDO):

$db->query("SELECT * FROM users WHERE id = :id", ['id' => $userId]);  
// No SQLi worries here!

Security.php (XSS/CSRF Protection):

$cleanInput = $security->sanitizeInput($_POST['data']);  
if ($security->verifyCsrfToken($token)) { /* Proceed safely */ }

4. Supercharged by AI and vQmod

SPMP’s AI-ready design lets developers collaborate with AI tools to:

  • Generate controllers/models from natural language prompts.
  • Debug errors using AI-suggested fixes.
  • Auto-document code based on standardized patterns.

And with vQmod, you can override core logic without hacking framework files. For instance, adding a search feature:

<?php  
// vmods/SearchMod.php  
class SearchMod {  
    public function addSearch($controller) {  
        $controller->search = function ($query) { /* Custom logic */ };  
    }  
}  
?>

5. Real-World Use Cases

SPMP excels in scenarios like:

  • ERP Systems: Manage inventory, HR, and finance with role-based access.
  • CRM Platforms: Track customer interactions and sales pipelines.
  • WMS Solutions: Optimize warehouse logistics with real-time updates.

Imagine building a hospital management system where AI generates appointment-scheduling modules while vQmod adds patient-specific workflows—all secured by SPMP’s built-in protections.

6. SPMP vs. The Giants

Feature SPMP Laravel/CodeIgniter
Learning Curve Minimal Moderate
Dependencies None Composer/Packages
Customization vQmod (non-invasive) Edit core files
AI Integration Built-in readiness Requires setup

SPMP isn’t here to replace Laravel—it’s here to fill a niche: lightweight, secure, and AI-collaborative systems.

7. Challenges to Consider

  • Community Size: SPMP’s ecosystem is young. You’ll trade Laravel’s vast packages for simplicity.
  • Scalability: Best for small-to-medium projects. Giant enterprises might need more firepower.

Conclusion: Why SPMP Matters

In a world where AI is reshaping development, SPMP offers a bridge between traditional coding and AI-assisted innovation. Whether you’re building a custom ERP or experimenting with AI-driven workflows, SPMP gives you the tools to move fast, stay secure, and keep your codebase clean.

Ready to try SPMP?

The future of PHP frameworks isn’t just about features—it’s about collaboration. SPMP is leading the charge.

Call to Action

Have you tried SPMP? Share your thoughts below or tweet your first project with #BuiltWithSPMP! 🚀

Popular

task manager: before clicking end process - part 2

continuation of the 1st part 1. igfxpers.exe - is a process installed alongside NVidia graphics cards and provides additional configuration options for these devices. "This program is a non-essential process, but should not be terminated unless suspected to be causing problems." processlibrary.com says its not a critical component. so there's nothing to worry about 2. igfxsrvc.exe - is a process associated with Intel(R) Common User Interface from Intel Corporation. It is installed with graphic card drivers with Intel chipsets. This program is important for the stable and secure running of your computer and should not be terminated. from processlibrary.com i wouldn't want to terminate this. 3. igfxtray.exe - is a process which allows you to access the Intel Graphics configuration and diagnostic application for the Intel 810 series graphics chipset. This program is a non-essential system process, and is installed for ease of use via the desktop tray. also ...

How AI is Revolutionizing Industries in the Philippines: Manufacturing, Healthcare, and Retail

The rise of artificial intelligence (AI) is reshaping industries around the globe, and the Philippines is no exception. As the country continues to embrace digital transformation, AI has become a game-changer for key sectors like manufacturing, healthcare, and retail. In this blog, we explore how AI is specifically transforming these industries and why it’s crucial for businesses to integrate AI solutions. AI in Manufacturing: Streamlining Processes and Boosting Efficiency Manufacturing is a vital part of the Philippine economy, and AI is poised to revolutionize this sector. AI can automate repetitive tasks, such as assembly and quality control, significantly improving production efficiency. Predictive maintenance powered by AI can prevent costly machine breakdowns by predicting potential failures before they occur. Additionally, AI’s ability to optimize supply chains ensures better inventory management and cost savings. With AI’s potential to reduce downtime, streamline logistics, and...

skyfire browser

I recently rediscovered skyfire browser. and when I say it's good, it's very good. it took me a day to get the hang of it on my samsung i780. after that, it's all worth the surf. still figuring out though, the multiple tab function. that's if ther's one. back when I first got this i780, I remember that i installed the older(i guess) version of skyfire which I didn't like. so, I opted for the opera. but I think i'll be switching again this time... oh, btw. im posting this entry with skyfire. just try to google it.