On Wednesday 24 Mar 2010 17:27:06 asagala wrote:
> I currently have a FrontController plugin that extends
> Zend-Controller_Plugin_Abstract. The preDispatch function is implemented in
> it. Everything works except for one thing. How can I prevent the
> preDispatch function to be applied to certain controllers? The only way I
> have right noew is to use $this->getRequest()->getControllerName() and
> compare it to a list of controller names.
> 
> Is there a better/easier way?

I can think of two options, but both not ideal. The first one is using the 
routeShutdown to fetch the route (and thus controller) and based on that info 
turn the plugin on or off.

The second is the option you use the controller's preDispatch() method. To 
avoid DRY the code inside the method could be replaced with an action helper.

Furthermore, I have no idea...
Regards, Jurian
-- 
Jurian Sluiman
CTO Soflomo V.O.F.
http://soflomo.com

Reply via email to