News Feed
Sections




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

Rob Allen's Blog:
Bootstrapping modules in ZF 1.8
July 09, 2009 @ 07:51:08

Rob Allen has posted a look at working with modules in the Zend Framework. His specific goal is to work with a model that's inside a module from inside another, different module (clear as mud? keep going!)

I've started to play with modules in a Zend Framework 1.8 application as the new autoloader means that all your model directories no long have to be on the include_path for autoloading to work. What I'm specifically interested in is being able to instantiate a model that is within a module from within another module. Setting it all up isn't that hard, but I couldn't find a concise description, so these are my notes on it.

To get it all working, he sets up things from the beginning - creating a new project, making a new model inside the module and linking it to the controller with the magic of autoloading. This last part does require a bit of work - you'll need to update your configuration files to let the framework know about this directory and make a bootstrap instance (extending Zend_Application_Module_Bootstrap) to pass the requests through.

0 comments voice your opinion now!
tutorial zendframework model module bootstrap


blog comments powered by Disqus

Similar Posts

Rob James' Blog: Configure Apache to run Tomcat and PHP

WebShop.com Blog: PHP Header(), Beyond Redirect

Wenbert Del Rosario's Blog: Registering your custom plugins in Zend Framework 1.8

Linode Library: Deploy High Performance Drupal Sites with Mercury on Ubuntu 10.04 (Lucid)

Pádraic Brady's Blog: Complex Views with the Zend Framework - Part 7: Zend_View Enhanced


Community Events





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


release podcast deployment zendserver language framework interview threedevsandamaybe bugfix list laravel series conference api introduction code symfony voicesoftheelephpant community tips

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