<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Zend Framework Module Init Script (Controller Plugin)</title>
	<atom:link href="http://www.toosweettobesour.com/2009/01/06/zend-framework-module-init-script-controller-plugin/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.toosweettobesour.com/2009/01/06/zend-framework-module-init-script-controller-plugin/</link>
	<description>Far Too Sweet To Be Sour</description>
	<lastBuildDate>Fri, 12 Mar 2010 14:46:01 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Daniel Cousineau</title>
		<link>http://www.toosweettobesour.com/2009/01/06/zend-framework-module-init-script-controller-plugin/comment-page-1/#comment-349</link>
		<dc:creator>Daniel Cousineau</dc:creator>
		<pubDate>Thu, 29 Jan 2009 01:34:54 +0000</pubDate>
		<guid isPermaLink="false">http://www.toosweettobesour.com/?p=251#comment-349</guid>
		<description>@Amit: Frankly you will need at least a controller directory, however what you can do is have your controller directory hidden away and use the module-specific errorcontroller plugin (http://www.toosweettobesour.com/2008/08/11/quickie-module-specific-error-controllers-in-zend-framework-15/) to select views to display.</description>
		<content:encoded><![CDATA[<p>@Amit: Frankly you will need at least a controller directory, however what you can do is have your controller directory hidden away and use the module-specific errorcontroller plugin (<a href="http://www.toosweettobesour.com/2008/08/11/quickie-module-specific-error-controllers-in-zend-framework-15/" rel="nofollow">http://www.toosweettobesour.com/2008/08/11/quickie-module-specific-error-controllers-in-zend-framework-15/</a>) to select views to display.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Amit sharma</title>
		<link>http://www.toosweettobesour.com/2009/01/06/zend-framework-module-init-script-controller-plugin/comment-page-1/#comment-342</link>
		<dc:creator>Amit sharma</dc:creator>
		<pubDate>Fri, 23 Jan 2009 09:04:20 +0000</pubDate>
		<guid isPermaLink="false">http://www.toosweettobesour.com/?p=251#comment-342</guid>
		<description>Can we Build a CMS in zend framework where controller directory is not used.
waiting for reply</description>
		<content:encoded><![CDATA[<p>Can we Build a CMS in zend framework where controller directory is not used.<br />
waiting for reply</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: blunt</title>
		<link>http://www.toosweettobesour.com/2009/01/06/zend-framework-module-init-script-controller-plugin/comment-page-1/#comment-329</link>
		<dc:creator>blunt</dc:creator>
		<pubDate>Fri, 09 Jan 2009 18:38:47 +0000</pubDate>
		<guid isPermaLink="false">http://www.toosweettobesour.com/?p=251#comment-329</guid>
		<description>Adding the Module loader to the addControllerDirectory would cause it be loaded on all requests, even if that request is not for that module - since the routing class has yet to determine what the requested module is and you&#039;d need to add the controllerDirectory in order to add it to the list of valid modules?

For the router plugin, certainly a good exercise of thought, another might be if that all respective application module controllers extended a base controller, then just doing that in the preDispatch &#039;could&#039; suffice? Reason for saying that is that a router plugin would not of been the first association of where &#039;to look&#039;, maybe.</description>
		<content:encoded><![CDATA[<p>Adding the Module loader to the addControllerDirectory would cause it be loaded on all requests, even if that request is not for that module &#8211; since the routing class has yet to determine what the requested module is and you&#8217;d need to add the controllerDirectory in order to add it to the list of valid modules?</p>
<p>For the router plugin, certainly a good exercise of thought, another might be if that all respective application module controllers extended a base controller, then just doing that in the preDispatch &#8216;could&#8217; suffice? Reason for saying that is that a router plugin would not of been the first association of where &#8216;to look&#8217;, maybe.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Daniel Cousineau</title>
		<link>http://www.toosweettobesour.com/2009/01/06/zend-framework-module-init-script-controller-plugin/comment-page-1/#comment-326</link>
		<dc:creator>Daniel Cousineau</dc:creator>
		<pubDate>Wed, 07 Jan 2009 20:40:10 +0000</pubDate>
		<guid isPermaLink="false">http://www.toosweettobesour.com/?p=251#comment-326</guid>
		<description>Ah, I see what you&#039;re saying.

I could easily modify my plugin to do a routeStartup(), I think you&#039;re still able to inject a route... However that would obviously have to dig through every module and include a file (in this case it may be best to move towards a file that contains a module class).

My code only needed to run only when in the specific module.</description>
		<content:encoded><![CDATA[<p>Ah, I see what you&#8217;re saying.</p>
<p>I could easily modify my plugin to do a routeStartup(), I think you&#8217;re still able to inject a route&#8230; However that would obviously have to dig through every module and include a file (in this case it may be best to move towards a file that contains a module class).</p>
<p>My code only needed to run only when in the specific module.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ralph Schindler</title>
		<link>http://www.toosweettobesour.com/2009/01/06/zend-framework-module-init-script-controller-plugin/comment-page-1/#comment-325</link>
		<dc:creator>Ralph Schindler</dc:creator>
		<pubDate>Wed, 07 Jan 2009 20:25:06 +0000</pubDate>
		<guid isPermaLink="false">http://www.toosweettobesour.com/?p=251#comment-325</guid>
		<description>Well, let me further explain the ideas behind putting it inside the addControllerDirectory().  In my mind there is a single driving factor: reusable modules.  In order for them to be drop in and go, some modules might need to have a place to bootstrap themselves, and this typically means prior to any &quot;dispatching&quot;.  This then allows modules (that are bootstrappable), to be able to inject routes (something that needs to happen before routeStartup), and to effectively &quot;bootstrap&quot; all their needs (even throw bootstrap exceptions).

To do this, the module would need to be hooked in during addControllerDirectory time.  The reasons for putting it inside the dispatcher is so that there is no prerequisite for any given reusable module to have the moduleInit plugin enabled.. it can simple expect to work in most, if not all, ZF FrontController environments.

Consider this the way that the FrontController (during bootstrap), delegating module bootstrap back to the Module, instead of forcing developers to add code to their bootstrap to make it run.

-ralph</description>
		<content:encoded><![CDATA[<p>Well, let me further explain the ideas behind putting it inside the addControllerDirectory().  In my mind there is a single driving factor: reusable modules.  In order for them to be drop in and go, some modules might need to have a place to bootstrap themselves, and this typically means prior to any &#8220;dispatching&#8221;.  This then allows modules (that are bootstrappable), to be able to inject routes (something that needs to happen before routeStartup), and to effectively &#8220;bootstrap&#8221; all their needs (even throw bootstrap exceptions).</p>
<p>To do this, the module would need to be hooked in during addControllerDirectory time.  The reasons for putting it inside the dispatcher is so that there is no prerequisite for any given reusable module to have the moduleInit plugin enabled.. it can simple expect to work in most, if not all, ZF FrontController environments.</p>
<p>Consider this the way that the FrontController (during bootstrap), delegating module bootstrap back to the Module, instead of forcing developers to add code to their bootstrap to make it run.</p>
<p>-ralph</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Daniel Cousineau</title>
		<link>http://www.toosweettobesour.com/2009/01/06/zend-framework-module-init-script-controller-plugin/comment-page-1/#comment-324</link>
		<dc:creator>Daniel Cousineau</dc:creator>
		<pubDate>Wed, 07 Jan 2009 19:37:29 +0000</pubDate>
		<guid isPermaLink="false">http://www.toosweettobesour.com/?p=251#comment-324</guid>
		<description>Personally I think we&#039;re best off with this functionality as a Controller Plugin that is included/enabled by default (essentially mimicking the ViewRenderer). (A) we&#039;ll be consistent with the standard built by the ViewRenderer, (B) keeps ZF modular (easy to extend), and (C) easy to disable as well as maintain.

However your approach of placing it as a custom dispatcher works well too.</description>
		<content:encoded><![CDATA[<p>Personally I think we&#8217;re best off with this functionality as a Controller Plugin that is included/enabled by default (essentially mimicking the ViewRenderer). (A) we&#8217;ll be consistent with the standard built by the ViewRenderer, (B) keeps ZF modular (easy to extend), and (C) easy to disable as well as maintain.</p>
<p>However your approach of placing it as a custom dispatcher works well too.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ralph Schindler</title>
		<link>http://www.toosweettobesour.com/2009/01/06/zend-framework-module-init-script-controller-plugin/comment-page-1/#comment-322</link>
		<dc:creator>Ralph Schindler</dc:creator>
		<pubDate>Wed, 07 Jan 2009 17:03:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.toosweettobesour.com/?p=251#comment-322</guid>
		<description>I actually had done the same thing a month or two back, only handled inside the dispatcher.  This &quot;feature&quot; is something we are considering in 1.8 along with the Zend_Application initiative.

You can see my prototype here:

http://svn.ralphschindler.com/repo/Scratch/ZFApp+ModuleInitSupport/library/ZendL/Controller/Dispatcher/Standard.php</description>
		<content:encoded><![CDATA[<p>I actually had done the same thing a month or two back, only handled inside the dispatcher.  This &#8220;feature&#8221; is something we are considering in 1.8 along with the Zend_Application initiative.</p>
<p>You can see my prototype here:</p>
<p><a href="http://svn.ralphschindler.com/repo/Scratch/ZFApp+ModuleInitSupport/library/ZendL/Controller/Dispatcher/Standard.php" rel="nofollow">http://svn.ralphschindler.com/repo/Scratch/ZFApp+ModuleInitSupport/library/ZendL/Controller/Dispatcher/Standard.php</a></p>
]]></content:encoded>
	</item>
</channel>
</rss>
