Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

MVC for advanced PHP developers [closed]

I need some help from more experienced programmers. I want to improve my MVC skills. But I could not find a good tutorial on Google for MVC. Google always gives "MVC for beginners".

I understand what MVC is and I can make it, but I'm not experienced enough to do something practical in OOP.

If anyone knows a good object-oriented tutorial for MVC, please direct me to the right place — I'm looking for good links, books etc.

like image 615
Ivan Avatar asked May 03 '13 10:05

Ivan


2 Answers

Links, that contain PHP-only materials, are marked with php for easier identification.

You cannot even begin to delve into MVC before you have comprehensive understanding of OOP. That include OOP practices (dependency injection, unit testing, refactoring) principles (SOLID, SoC, CQS, LoD) and common patterns (and no, singleton is not an object-oriented pattern).

MVC is an advanced architectural design pattern, which requires solid understanding. It is not meant for beginners or for tiny "hello world" applications. One uses MVC to add additional constraints to the codebase, when simple adherence to OOP practices becomes too loose to control the codebase.

The best I can suggest for you would be to begin by expanding you knowledge regarding object oriented code:

  • Clean Code I: Arguments
  • Clean Code III: Functions

The two lectures above should cover the basics. And then move on to:

  • Inheritance, Polymorphism, & Testing
  • Unit Testing
  • Global State and Singletons
  • Don't Look For Things!

When you understand all that was explain in this series, you can expand on:

  • Don't be STUPID, Grasp SOLID! php
  • The Principles of Agile Design
  • Advanced OO Patterns (slides)php
  • Beyond Frameworks (slides)php
  • Agility and Quality php
  • Beyond Design Patterns php

Also, I would strongly recommend for you to read (in this order):

  • Design Patterns Explained
  • GUI Architectures
  • Inversion of Control Containers and the Dependency Injection pattern
  • Patterns of Enterprise Application Architecture
  • Domain-Driven Design: Tackling Complexity in the Heart of Software

P.S.: you might also take a look at this book (cautiously, because it has issues): Guide to PHP Design Patterns php

like image 126
tereško Avatar answered Nov 13 '22 00:11

tereško


What I recommend to you is a book about design patterns. Most of these books also cover the MVC pattern and the other patterns are worth to know if you building a complete framework.

One good book is PHP Design Patterns. I don't know if it exists in english but I would search for other books and compare the contents.

like image 1
bitWorking Avatar answered Nov 13 '22 01:11

bitWorking