PHP – Introduction to MVC Frameworks

Posted by Andrew, 3 months and 2 weeks ago.
  1. Introduction
  2. Requirements
  3. Creating the Directory Structure
  4. Controllers
  5. Libraries
  6. Models
  7. Helpers
  8. Views
  9. Making It Work
  10. Demo and Download
  11. Conclusion

Introduction

Have you ever found yourself using procedural code on projects, and when it comes to modifying different elements you spend an outrageous amount of time updating code, removing code, or digging through code that overlaps other parts of your code numerous times? Yeah… procedural can be a nightmare in large websites, so this is why Object-Oriented Programming with PHP can save you plenty of time in this process.

One use of OOPPHP is using an MVC (Model View Controller) framework to develop your applications. Of course, you can download already built MVC frameworks such as CodeIgniter, CakePHP, or the Zend Framework; but all of those can be extremely bloated if you are developing smaller applications that wont utilize everything they have to offer. Also, you may be like me, you love to reinvent the wheel to see how the wheel works; so developing your own MVC is an excellent way to help you understand the concept behind OOP.

This tutorial will walk you through all the initial steps to getting an MVC framework up and running. In the future, I will add additional tutorials that will show you how to implement session management, template management, etc, into this framework. For now, this will just show you the basic concept behind the framework using libraries, models, helpers, and views.
Lets get our hands dirty shall we?

Pages:[1]234567891011

Community Thoughts

There are currently no toughts from the community, want to share yours?

What are your thoughts?