Welcome Guest, Not a member yet? Register   Sign In
I need your help winning a major battle for Codeigniter
#17

[eluser]Rick Jolly[/eluser]
The primary aim of the Zend Framework claims to be simplicity. They have some great components, but MVC is anything but simple.

Here are some of my gripes:
Quote:1. Naming conventions

PEAR style naming conventions where class names map to directories are excellent and necessary for autoloading. ZF uses those conventions except with MVC.

Autoloading resources such as models aren't easily achieved. To address this, ZF updated their autoloader and introduced a resource autoloader. Now the code and usage is much too complex.

Controllers should be loaded automatically from any directory without having to explicitly add controller or module directories to the front controller. Remember convention over configuration? This would be possible by allowing for PEAR style naming conventions.

2. Helpers

Controller and View helpers are kept in separate files which means occasional code duplication.

To access a controller helper you have to type $this->_helper->SomeHelper. Why not a generic factory method, or more simply forget objects and use static methods directly. I know the testability argument against static classes, but those without class variables should be fine, correct?

View helpers are abstracted away such that each helper method must be in its own class. Static methods accessed directly from the view are simpler and more transparent. If these helpers must be objects, then just use a factory class.

3. Aversion to extract() and static methods

In view files we must use $this to access a variable or helper. That is a lot of unnecessary typing. The php extract() function could have been used for variables. Static methods could have been used for helpers.

4. Over engineering

If the ZF must be case study of design patterns, then at least get it right. Currently, one thing that bothers me is that the front controller contains the dispatcher, and the dispather contains the front controller. Like a "circular reference".

I hope Ralph and others are listening to the criticisms. ZF, currently at version 1.9, has a great opportunity to rethink their MVC implementation in version 2.0. Hopefully they are listening.


Messages In This Thread
I need your help winning a major battle for Codeigniter - by El Forum - 07-18-2009, 10:41 AM
I need your help winning a major battle for Codeigniter - by El Forum - 07-18-2009, 11:33 AM
I need your help winning a major battle for Codeigniter - by El Forum - 07-20-2009, 03:23 PM
I need your help winning a major battle for Codeigniter - by El Forum - 07-20-2009, 05:08 PM
I need your help winning a major battle for Codeigniter - by El Forum - 07-20-2009, 10:04 PM
I need your help winning a major battle for Codeigniter - by El Forum - 07-21-2009, 01:45 AM
I need your help winning a major battle for Codeigniter - by El Forum - 07-21-2009, 07:58 AM
I need your help winning a major battle for Codeigniter - by El Forum - 07-21-2009, 08:32 AM
I need your help winning a major battle for Codeigniter - by El Forum - 07-21-2009, 08:44 AM
I need your help winning a major battle for Codeigniter - by El Forum - 07-21-2009, 08:57 AM
I need your help winning a major battle for Codeigniter - by El Forum - 07-21-2009, 10:25 AM
I need your help winning a major battle for Codeigniter - by El Forum - 07-21-2009, 03:15 PM
I need your help winning a major battle for Codeigniter - by El Forum - 08-13-2009, 11:03 AM
I need your help winning a major battle for Codeigniter - by El Forum - 08-13-2009, 12:53 PM
I need your help winning a major battle for Codeigniter - by El Forum - 08-13-2009, 01:48 PM
I need your help winning a major battle for Codeigniter - by El Forum - 08-13-2009, 03:54 PM
I need your help winning a major battle for Codeigniter - by El Forum - 08-13-2009, 05:47 PM
I need your help winning a major battle for Codeigniter - by El Forum - 08-13-2009, 06:39 PM



Theme © iAndrew 2016 - Forum software by © MyBB