Re: [fw-general] why is every module bootstrap executed during initialization?

2009-12-17 Thread Matthew Weier O'Phinney
-- Guillaume ORIOL wrote (on Wednesday, 16 December 2009, 11:18 PM +0100): > Thank you Matthew but I don't understand your last remark. > > Let's say I have two modules, each of which has its own plugin > registered at bootstrap: > class Default_Bootstrap extends Zend_Application_Module_Bootstrap

Re: [fw-general] why is every module bootstrap executed during initialization?

2009-12-16 Thread Greg
A work around could be to not specify the modules directory but instead specify the controller directory of the module in question (in Application/Bootstrap) - in this case each module would have their own bootstrap (index.php) script and the current module name could be specified in a respective c

Re: [fw-general] why is every module bootstrap executed during initialization?

2009-12-16 Thread Hector Virgen
You can test the request from within your plugin: public function dispatchLoopStartup(Zend_Controller_Request_Abstract $request) { if ('admin' != $this->_request->getModuleName()) { return; } // Perform pluginy things here } -- Hector On Wed, Dec 16, 2009 at 2:18 PM, Guilla

Re: [fw-general] why is every module bootstrap executed during initialization?

2009-12-16 Thread Guillaume ORIOL
Thank you Matthew but I don't understand your last remark. Let's say I have two modules, each of which has its own plugin registered at bootstrap: class Default_Bootstrap extends Zend_Application_Module_Bootstrap { public function _initPlugin() { $plugin = new Plugin_Foo();

Re: [fw-general] why is every module bootstrap executed during initialization?

2009-12-16 Thread Matthew Weier O'Phinney
-- Guillaume ORIOL wrote (on Wednesday, 16 December 2009, 09:33 PM +0100): > I wonder why, in a modular application, all module bootstraps are > executed during initialization and not only the one corresponding to > the matched module? > > What would be the way to get only one of them executed (I

Re: [fw-general] why is every module bootstrap executed during initialization?

2009-12-16 Thread Cristian Bichis
Hi, Let's suppose you have module1 and module2 and matched module is module1 and things are working as you said, just the matched module get bootstrapped... But, what if into a module1 action you make use of something like this: Module2_Model_Whatevermodel()... ? Would be an error because

[fw-general] why is every module bootstrap executed during initialization?

2009-12-16 Thread Guillaume ORIOL
Hi, I wonder why, in a modular application, all module bootstraps are executed during initialization and not only the one corresponding to the matched module? What would be the way to get only one of them executed (I would like to connect a different plugin to each module)? Thanks -- Guil