ZF-792: Components (Symfony-like defenition) in MVC
Description
I didn't found in ZFW future like component is Symfony. I'm writen it. http://rt.avlab.ru/wp-content/uploads/…
For more information see http://rt.avlab.ru/2007/01/… (russian)
If you know more right way, notify me, please.
Comments
Posted by Bill Karwin (bkarwin) on 2007-01-25T09:05:18.000+0000
Assign to Matthew.
Posted by Matthew Weier O'Phinney (matthew) on 2007-01-29T09:37:13.000+0000
From reviewing the code, it looks like this is a Zend_View helper class designed to allow pulling in content from another controller action, and that it has some amount of caching included in the interface.
What I'm wondering is: why would you do this instead of using _forward() in the action controller? Can you give me some details on what prompted this particular design, and use cases?
Thanks!
Posted by Roman Tolkachyov (rammstein) on 2007-01-29T11:09:32.000+0000
That's right - this is a Zend_View helper. Some code for example
indexView.php
We don't need to controll call chain in controller by using _forward(). In other way we should notify next controller2 about what controller3 it must forward to and then notify controller 3 what controller4 must forward to etc. It very hard.
In other way we should modify _forward() to allow constructions like that:
it's means, that next action is 'component1' and after it will execute action component2 will start etc.
But it isn't right alternative. I can't say rightly why, because I have troubles in my english :) You may read symfony-book by this subject.
Posted by Matthew Weier O'Phinney (matthew) on 2007-11-16T10:31:50.000+0000
Please review the Zend_View_Helper_Action view helper in the incubator. This component will be available for the 1.1.0 release as part of the Zend_View Enhanced proposal, and accomplishes what you've outlined.
Posted by Matthew Weier O'Phinney (matthew) on 2007-12-11T15:10:54.000+0000
Action view helper merged to core.