You could use a controller plugin and add the path via:
Zend_Layout::getMvcInstance()->getView()->addScriptPath()

The request can be accessed within the plugin ($this->getRequest()); 

Michel Morelli wrote:
> 
> Hi all.
> 
> In my bootstrap I have this line :
> 
> $frontController->addModuleDirectory(ROOT_DIR.'/application/modules');
> $frontController->setDefaultModule('frontend');
> 
> So I can split my application/web site in "modules". And it works. Now I 
> need to use viewScript Decorator in my Zend_Form's forms. So I have 
> thinked to write the "html" form in a directory called forms inside the 
> {module_name}/views/ directory. I know that I need to use 
> "addScriptPath", but I don't understand how can I retrive the module 
> name inside the bootstrap (before dispatch()) or add a script path after 
> the dispatch().
> 
> M.
> 
> -- 
> Michel 'ZioBudda' Morelli                       [email protected]
> Consulenza sistemistica in ambito OpenSource.
> Sviluppo applicazioni web dinamiche (LAMP+Ajax)
> Telefono: 0200619074
> Telefono Cell: +39-3939890025 --  Fax: +39-0291390660
> 
> http://www.ziobudda.net                         ICQ: 58351764  
> http://www.ziobuddalabs.it                      Skype: zio_budda
> http://www.ajaxblog.it                                MSN: 
> [email protected]                   
>                                               JABBER: [email protected]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Add-ScriptPath-based-on-module-name-tp21474810p21475815.html
Sent from the Zend Framework mailing list archive at Nabble.com.

Reply via email to