News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Migrating to ZF2:
Integrating Composer and DoctrineORMModule
November 14, 2013 @ 12:23:52

Zend Framework v2 has been out for a good while now, but there's still applications out there running on the v1 of the popular framework. Since there was such a fundamental change in structure and functionality between v1 and v2, simply upgrading isn't possible - you have to migrate. Fortunately, there's guides like this one from Chris Strosser that shows you how to get there gradually.

Due to the vast nuances of Zend Framework 2, migrating an application from Zend Framework 1 can be very tedious. To make this process a little less painful, there is a way to slowly implement modules from ZF2 without making the application unusable. The methodology illustrated, which implements DoctrineModule and DoctrineORMModule into a Zend Framework 1 project, can be applied to a variety of ZF2 modules, making it an invaluable technique in the migration process.

Using these two ZF1 modules, they show how to integrate them into a typical ZF2 structure. There's a few steps in the process:

  • Add init_autoloader.php to application root directory
  • Update ZF1′s index.php for Composer compatibility
  • Setup ZF2 configuration files
  • Setup ZF2 "Application" module
  • Relocate existing entities and repositories to ZF2
  • Make ZendMvcApplication available in ZF1

It's not an overly complex process, it just requires the right configuration settings and component placement to get the ZF1 module to cooperate in the world of ZF2.

0 comments voice your opinion now!
zendframework1 zendframework2 module migrate gradual composer

Link: http://webjawns.com/2013/11/migrating-to-zf2-integrating-composer-and-doctrineormmodule/

blog comments powered by Disqus

Similar Posts

VG Tech: Swagger Docs in ZF2 with Examples - Part 2: Swagger UI

Master Zend Framework: Accessing ServiceManager Services in Controller Plugins

MaltBlue.com: Zend Framework 2 ServiceManager - Web Application Development Simplified

SitePoint PHP Blog: Git Hooks for Fun and Profit

MaltBlue.com: Easy Setter Injection in Zend Framework 2


Community Events





Don't see your event here?
Let us know!


framework developer library zendserver introduction tips bugfix threedevsandamaybe release list language laravel opinion deployment interview community symfony api series podcast

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework