To Use a PHP Framework or Not? [closed] To Use a PHP Framework or Not? [closed] codeigniter codeigniter

To Use a PHP Framework or Not? [closed]


What are the benefits of using MVC PHP frameworks ?

Well there are many benefits of using PHP frameworks, let’s see some of the main benefits of using them.

  1. These PHP frameworks follow some design pattern, so when you use a framework you have to follow their coding convention, which makes your code clean and extensible for future purposes.
  2. The Popular PHP frameworks like CakePHP, CodeIgniter, Zend Framework, Symfony follow Model View Controller (MVC) design pattern which separates business logic from user interface, also making the code cleaner and extensible.
  3. As everybody can guess, these frameworks contain a lot of libraries to make your job easier. For example: to validate a form you don't have to write as much code as you have to do in normal coding scenario (without using a framework), just a few lines of code calling the library is usually enough for it.
  4. While working on a large project in a team, an MVC PHP framework will be a great tool for development as you can assign a developer to develop one part of a module for a developer and integration will be quite easy of these developed modules at final level.
  5. These MVC frameworks really help you to develop the project rapidly, if you know a framework well then you'll never worry about the project deadline.
  6. Most of these MVC frameworks use clear url approach making your web project SEO friendly.

check article


My philosophy is that you should only use something when it solves a need that you currently have.

There's a real tendency, particularly in this realm, to simply use a framework for the sake of using one or because you feel like you should be using something. I discourage such practices. Also frameworks I think have the most value when you've done things the hard way so you have a good understanding of what problems you have and how the framework can help you in that situation. Framework choice does depend on the situation.

That all being said, the MVC pattern with Web applications is useful so it certainly wouldn't hurt you to learn at least one. I'd stick to a fairly minimalist framework however. CodeIgniter springs to mind here.

Lastly, the other danger with frameworks is that they can be so invasive that you're no longer doing PHP, you're doing CakePHP, Symfony or whatever. That's not necessarily a problem but the danger in it being so invasive is you don't get a good grounding in PHP and if you ever want to change it'll simply be too hard that you'll never be able to do it.


One of the great perks of PHP frameworks are that they minimize reinventing the wheel in a great number of common web application needs. Security issues, graceful exception handling, RESTful URLs, and reusability of code across your site are fairly universal considerations.

It may be easier to familiarize yourself with the tools of a framework and then see if you want to take on the full MVC system it supports. For that end, I'd suggest familiarizing yourself with the Zend Framework. ZF works as a library of classes which can be implemented individually for particular uses--anything from security to Lucene search--but contains classes which, when used together, implement a fully fleshed out MVC paradigm.