I've got a project developed circa Zend Framework 1.7 that I'd like to migrate to Zend Tool and ZF 1.9.4pl1. The main benefit I hope to gain is to be able to use automatic loading of Models, Forms, etc. In other words, I want to eliminate all of these little methods:
protected function _getSurveyForm() { require_once APPLICATION_PATH . '/forms/Survey.php'; $form = new Form_Survey(); $form->setAction($this->_helper->url('survey')); return $form; }
My strategy was going to be this. First,
zf create project foo
zf create controller bar
zf create controller arf
etc.
until I managed to recreate the structure for all the controllers, views, etc. Second, I was going to copy in my existing controllers, views, models, etc., overwriting the stubs created by zf tool, and making sure that all my class names and file names lined up.
Is this the best way to go? Am I confused thinking that I'm going to be able to eliminate the little loader methods like _getSurveyForm() above?