views:

237

answers:

4

I'm looking for a good framework for PHP and see most offer the MVC approach, are there any other (or better) design methods/approaches that would be considered more efficient or best practice? MVC is starting to look dated but I wanted to know if it's still considered the industry standard.

A: 

MVC is still the industry standard for every Object Oriented web development language.

However you are afforded some alternate routes:

  1. Micro Frameworks (Google Them) (which most often still use MVC design patters, just not as formalized and some not in an Object Oriented fashion)
  2. Event-Based Frameworks (like PRADO)

However beyond those routes you are a bit out of luck as far as I know.

Thanks Xeoncross, forgot to add the "micro usually are still mvc" caveat

dcousineau
Actually, micro frameworks like MicroMVC do use MVC.
Xeoncross
Thanks I will look into these
Phill Pafford
Xeoncross: hmm, I thought I had added that in (I had a long post I was writing then scrapped it and wrote the shorter version)...
dcousineau
A: 

Well, in all truth MVC is actully misleading when it comes to most frameworks. I don't know of any PHP system that is only based on Models, Views, & Controllers. Most of them also use functions, libraries, configs, and caching levels as well.

MVC is merely a starting point stating that abstraction of your CRUD from your business logic and views is good a good thing! From there you can abstract as much more of the system as you want from template parsers to libraries that calculate physics.

Xeoncross
Even pure MVC doesn't preclude libraries and other abstractions. MVC by definition is the code execution path only flows between models, views, and controllers with those areas only performing certain tasks. Technically a 3rd party library for physics calculation would be considered a model, as (contrary to some popular belief) a model is not exclusively a table gateway class as some frameworks might lead one to believe.
dcousineau
A: 

I would recommend symfony framework as my ideal ;)

http://www.symfony-project.org/

FractalizeR
A: 

The only PHP frameworks that I am aware of that are well tested use the MVC pattern however there has been some web based frameworks that use the Naked Objects pattern for other languages like Java.

In case you are interested it looks like there is at least one Naked Object framework under way for PHP also here:

Naked object PHP blog

Jai