3 ms·
I sort of evolved my own PHP framework pattern after I did my first few webdev jobs and identified the problem areas. This was before I had ever used a MVC fram
by geon 14y ago
I sort of evolved my own PHP framework pattern after I did my first few webdev jobs and identified the problem areas. This was before I had ever used a MVC framework.
Looking back at it now, it had everything your typical web MVC framework has, just slightly diffrent:
* Models, with cleanly encapsulated functionality, but without an ORM. I only built small websites, so all related database tables were managed by the same model.
* Controllers that handled all input and delegate it to models.
* Views in the form of HTML code following the controller code in the same file, but strictly separated.
* "Forms" that abstracted away the controller/view and input validation of forms in a neat, reusable package.
My point is that whatever you come up with that actually works well and lets you be productive will more-or-less resemble MVC.